[英]NativeScript - How to prevent CSS minification?
I've got NativeScript 3.3.0 installed. 我已经安装了NativeScript 3.3.0。 My project-wide CSS is in
app/app.css
. 我在项目范围内的CSS在
app/app.css
。
When I run the app, either by console 当我运行应用程序时,可以通过控制台
tns run android --device [device-ID of my preferred emulator]
or by starting it in an Android emulator through JetBrain's WebStorm (with NativeScript plugin installed), the app.css
always gets minified during the rebuilding process after I do some changes to it while the app is running. 或通过JetBrain的WebStorm(安装了NativeScript插件)在Android模拟器中启动它,在我对应用程序运行时进行一些更改之后,
app.css
始终在重建过程中app.css
。
Is it somehow possibile to prevent NativeScript from minifying the CSS file upon building the app? 阻止NativeScript在构建应用程序时缩小CSS文件是否可行? I wished there was a run parameter with which I could toggle that.
我希望有一个运行参数可以切换该参数。
Looks like you have nativescript-dev-sass installed if you uninstall it, the minification should stop. 如果您卸载了它,则好像已安装了nativescript-dev-sass,缩小过程应停止。
But ideally, you would want to keep the minification. 但理想情况下,您将希望保持最小化。
Edit: 编辑:
you can do, npm remove -D nativescript-dev-sass
可以,
npm remove -D nativescript-dev-sass
and you remove those nativescript-dev-sass files which are in hooks folder (if it doesn't get removed automatically). 并删除了hooks文件夹中的nativescript-dev-sass文件(如果未自动将其删除)。
Also if you see node-sass
in your devDependencies, remove that as well with 另外,如果您在devDependencies中看到
node-sass
,也可以通过以下方式将其删除
npm remove -D node-sass
and you should be good to go. npm remove -D node-sass
,您应该一切顺利。 Cheers! 干杯!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.