参考:
CSS Naming Conventions that Will Save You Hours of Debugging
Class Name
use hypen
.hero-section {}
JS Used Class Name
add prefix "js"
class="js-hero-section"
好处是比较 clear, 解耦也比较顺风水.
2023-10-10 17:42:52
CSS Naming Conventions that Will Save You Hours of Debugging
use hypen
.hero-section {}
add prefix "js"
class="js-hero-section"
好处是比较 clear, 解耦也比较顺风水.