fes.js/docs/reference/plugin/plugins/sass.md
2021-07-27 16:23:00 +08:00

28 lines
528 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# @fesjs/plugin-sass
## 介绍
Fes.js 默认只支持 `less`,通过此插件扩展支持 `sass`
## 启用方式
`package.json` 中引入依赖:
```json
{
"dependencies": {
"@fesjs/fes": "^2.0.0",
"@fesjs/plugin-sass": "^2.0.0"
},
}
```
## global css
添加 `src/global.scss``src/global.sass` 为全局CSS入口添加一些通用样式内容。
## Vue 单文件组件
Vue 单文件组件的 `<style></style>` 添加 `lang='scss'`,例如:
```vue
<style lang="scss">
</style>
```