Comments (8)
嗯,可以的,用样式覆盖的写法,当然 vite
也可以加配置项
vite.config.ts
import { ViteWeappTailwindcssPlugin as vwt, postcssWeappTailwindcssRename } from 'weapp-tailwindcss-webpack-plugin'
...
postcssPlugins.push(
postcssWeappTailwindcssRename({
cssPreflight: {
'box-sizing': false,
},
})
);
你可以看我 demo
里的 uni-app-vue3-vite
from weapp-tailwindcss.
配置项里,有一个 cssPreflight
配置项,你可以把它配置成:
cssPreflight: {
'box-sizing': false,
'border-width': '0',
'border-style': 'solid',
'border-color': 'currentColor'
}
来禁用盒模型
from weapp-tailwindcss.
效果详见 https://github.com/sonofmagic/weapp-tailwindcss-webpack-plugin#options
from weapp-tailwindcss.
from weapp-tailwindcss.
你好,这是哪一个个配置项?
from weapp-tailwindcss.
我用的是Vite
from weapp-tailwindcss.
from weapp-tailwindcss.
嗯,可以的,用样式覆盖的写法,当然
vite
也可以加配置项vite.config.ts import { ViteWeappTailwindcssPlugin as vwt, postcssWeappTailwindcssRename } from 'weapp-tailwindcss-webpack-plugin' ... postcssPlugins.push( postcssWeappTailwindcssRename({ cssPreflight: { 'box-sizing': false, }, }) );你可以看我
demo
里的uni-app-vue3-vite
感谢,已经用这种配置方式解决
from weapp-tailwindcss.
Related Issues (20)
- mpx编译wxml属性值单引号 HOT 3
- 而你,我的朋友,你是真正的英雄 HOT 1
- 使用原生小程序开发模板时,如何使用其他npm包? HOT 2
- 是否支持引用外部包组件? HOT 2
- taro3 + reactjs + weapp-tailwindcss css 语法转义不成功 HOT 2
- vite how to px 2 rpx HOT 2
- uniapp vue3环境下使用,有时候会出现类名未生成样式的情况 HOT 4
- 有单独的 JS API 么? HOT 3
- hbuilder原生创建的项目无法使用webpack5,如何升级? HOT 1
- v3 大版本改动与迁移 HOT 1
- TypeError: Cannot destructure property 'Compilation' of 'compiler.webpack' as it is undefined. HOT 2
- taro rn模式适配 HOT 1
- [postcss] text.replaceAll is not a function HOT 2
- tailwindcss v2 版本下开启 TAILWIND_MODE=watch 的环境变量会导致高版本 hbuilderx 重复差量编译 HOT 8
- 请问支持 app-nvue 吗? HOT 3
- 是否支持使用taro+weap-tailwindcss开发京东小程序, HOT 1
- 新创建的Taro项目按指南配置后,出现wxml文件编译错误 HOT 1
- htmlparser2 更新之后, 导致 wxml 编译失败, 缺少最后的引号 HOT 1
- 谁在使用 weapp-tailwindcss ? HOT 12
- @layer中自定义的类偶尔会失效 HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from weapp-tailwindcss.