nextjs/no-styled-jsx-in-document Correctness ​
What it does ​
Prevent usage of styled-jsx in pages/_document.js.
Why is this bad? ​
Custom CSS like styled-jsx is not allowed in a Custom Document.
Example ​
javascript
How to use ​
To enable this rule in the CLI or using the config file, you can use:
bash
oxlint --deny nextjs/no-styled-jsx-in-document --nextjs-plugin
json
{
"plugins": ["nextjs"],
"rules": {
"nextjs/no-styled-jsx-in-document": "error"
}
}