Conversation
cfnelson
left a comment
There was a problem hiding this comment.
Out of curiosity have you looked at or used css-modules or radium though radium is react specific. Kind of like css-modules as it isn't framework dependent.
| * Use hex values for colors when possible. | ||
| * Don't specify a unit after using a 0 value. | ||
| * Avoid nesting more than 2 levels, unless pseudo classes. | ||
| * Use |
| # HTML | ||
|
|
||
| ## Formatting | ||
| * Don't use inline styles, unless you are generating dynamic styles in your templating system. |
There was a problem hiding this comment.
Some Inlining of styles is recommended or advocated for performance. e.g - displaying above the fold content. Check here and let me know what you think ? Can maybe add some reference or content from this ?
There was a problem hiding this comment.
We should always start with the most maintainable thing until/unless there's a specific need for some sort of gnarly optimization. I think @oliverthomasklein is trying to write general guidelines.
|
Also, I do not know enough on HTML/CSS to give a strong/assertive opinion on best style/practices. Should get @karldanninger in on this review :) Nice work otherwise :) |
|
Hehe, I might start advocating we write all of our styles in JavaScript |
| # HTML | ||
|
|
||
| ## Formatting | ||
| * Don't use inline styles, unless you are generating dynamic styles in your templating system. |
There was a problem hiding this comment.
We should always start with the most maintainable thing until/unless there's a specific need for some sort of gnarly optimization. I think @oliverthomasklein is trying to write general guidelines.
|
|
||
| ## Formatting | ||
| * Don't use inline styles, unless you are generating dynamic styles in your templating system. | ||
| * Only use ID's to be targeted my JS. |
|
Instead of a sass style guide should it just be for CSS in general? |
|
@pauldowman I was pretty unsure on this. A lot of the formatting is redundant if you are using CSS. I looked at how Thoughtbot did it, they used sass. I think it's more accurate. |
|
@oliverthomasklein @karldanninger This has been sitting around for quite some time. So long that we are now using Styled Components. 😂 Would love to get this refactored and merged in. Happy to help and provide my perspective as well to help push this along. Some suggestions:
Going to pull in @xavcz as well as I am sure he will have/add some 🔥 and insight. Would you be interested in giving any thoughts or dot points xavs? Will be happy to type/clean them up for you as I know you are extremely busy. 👷 |
|
🤐 no opinion. Use whatever fits the job, the project structure & the team: don't be dogmatic, there is no 1 solution fit all. |
|
@xavcz I might have not communicated the purpose of this PR properly. Sorry 😞 . This section of the OK GROW! guides is our Even your comment of |
|
Closing, but content should be re-used! |
@cfnelson @karldanninger