Use Scss to implement css has func(使用scss实现css中has函数)
has
has in css
The functional :has() CSS pseudo-class represents an element if any of the relative selectors that are passed as an argument match at least one element whe…
需求:后端要传入不同的等级,前端通过等级展示不同的字体颜色,通过scss遍历更有利于动态修改颜色或者增删等级
1.通过 for $i from 1 through 4 定义循环,索引值为i
2.nth($colors, $i) 取出对应的颜色
$colors: #ff0000, #00ff…
概述
When using Vue components, the Vite compiler allows you to use almost any frontend templating language style. The easiest way to enable these expressive library plugins in your Vue templates is to install them when you initialize your project, or by …