vue系列---【UI库、VScode编辑用户代码片段、stylus css预处理器】
2021-05-28 03:02
标签:lib 移动端 tar variable exp ble 引入 font important 栅格布局、布局、button、form、data展示、反馈组件、其他 https://element.eleme.cn/#/zh-CN http://v1.iviewui.com/ https://vant-contrib.gitee.io/vant/#/zh-CN/ 目录 使用:home.vue 如果使用UI框架,需要修改样式,优先级要高于UI框架。 1.important 2.如果1失败了,那么就使用穿透 创建项目,有一个css-pre… css预处理器选上,然后选择less. Color.less index.less 引入所有的less文件 组件中使用less 编辑器左下角—》设置—》用户代码片段—》新建用户代码片段—》输入代码片段名称—》 vue系列---【UI库、VScode编辑用户代码片段、stylus css预处理器】 标签:lib 移动端 tar variable exp ble 引入 font important 原文地址:https://www.cnblogs.com/chenhaiyun/p/14788017.html1.Vue 组件库(UI库)
element-ui PC端
1.官网:
2.下载
npm i element-ui --save
3.引入
//引入element-ui
import ElementUI from ‘element-ui‘;
import ‘element-ui/lib/theme-chalk/index.css‘;
Vue.use(ElementUI);
ivew-ui PC
Vant 移动端
2.stylus--css预处理器
版本:
"stylus": "^0.52.3",
"stylus-loader": "^3.0.1",
安装:
npm i stylus@0.52.3 stylus-loader@3.0.1 --save
使用:
-stylus
index.styl //整合样式
color.styl //颜色
size.styl //大小
form.styl //表单
table.styl //表格
穿透:
h3
color $primary !important
.con >>> h3{
color:$primary;
}
3.less--css预处理器
-src
-less
index.less
color.less
size.less
....
@primary: #ff4400;
@success: lime;
@warn: orange;
@import "./color.less";
@import "./size.less";
4.VScode编辑用户代码片段
{
// Place your global snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and
// description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope
// is left empty or omitted, the snippet gets applied to all languages. The prefix is what is
// used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders.
// Placeholders with the same ids are connected.
// Example:
"Print to console": {
"scope": "javascript,typescript,vue",
"prefix": "u-log",
"body": [
"console.log(\"这是我的打印\")",
"console.log($0)"
],
"description": "Log output to console"
}
}
文章标题:vue系列---【UI库、VScode编辑用户代码片段、stylus css预处理器】
文章链接:http://soscw.com/essay/88489.html