摘要: Sass入门(二) 一、函数 p { color: hsl(0, 100%, 50%); } 编译为 p { color: #ff0000; } 二、插值语句 `# 通过 #{} 插值语句可以在选择器或属性名中使用变量: $name: foo; $attr: border; p.#{$name} { 阅读全文
posted @ 2021-06-15 14:18 levewei 阅读(61) 评论(0) 推荐(0)
摘要: 一、sass安装 sass需要安装ruby,先从官网下载安装ruby,安装时需要勾选Add Ruby executables to your PATH添加到系统环境变量。 安装完成后,使用下面命令测试是否安装成功: ruby -v 安装成功后切换国内源: gem update --system // 阅读全文
posted @ 2021-06-15 14:17 levewei 阅读(101) 评论(0) 推荐(0)
摘要: class与style绑定 <div v-bind:class="{active: isActive}"> </div> data(){ return{ isActive: true } } 绑定内联样式: <div v-bind:style="{ color: activeColor, fontS 阅读全文
posted @ 2021-06-15 14:15 levewei 阅读(72) 评论(0) 推荐(0)