Lint check to avoid inline styling
See original GitHub issueA lint check to avoid inline styling in HTML files should be implemented. Instead, there should be a separate CSS class for it.
Examples:
Good pattern:
<div class="oppia-some-class-name">
......
</div>
Bad patterns:
<div style="width: 60%;">
......
</div>
OR
<div class=""oppia-some-classname" style="width: 60%;">
......
</div>
Issue Analytics
- State:
- Created 5 years ago
- Comments:12 (8 by maintainers)
Top Results From Across the Web
Are there lint to detect CSS inline style which no need to used ...
I would recommend looking into CSS Modules. They enable you to add css to your React components on a per component basis. For...
Read more >eslint-plugin-no-inline-styles - npm
ESLint for no inline styles allowed. Latest version: 1.0.5, ... Start using eslint-plugin-no-inline-styles in your project by running `npm i ...
Read more >Inline Styles: Yes or No? - EngineYard
Stéphane Derosiaux did a simple performance test comparing the two, and it does indeed seem that inline styles are slower. However, these ideas ......
Read more >Why you shouldn't use inline styling in production React apps
One of the main reasons that inline styling is not a good choice for your application is because it does not support (or...
Read more >Inline Styles in HTML - Codecademy
Inline Style Syntax. Inline styles look and operate much like CSS, with a few differences. Inline styles directly affect the tag they are...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
If you do it properly, this change should not be visible to the user. And yes, as part of this ticket, you’ll have to fix it in all of the places that violate this rule.
Filed #8423