0

I've got NativeScript 3.3.0 installed. My project-wide CSS is in 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.

Is it somehow possibile to prevent NativeScript from minifying the CSS file upon building the app? I wished there was a run parameter with which I could toggle that.

1 Answer 1

2

Looks like you have nativescript-dev-sass installed if you uninstall it, the minification should stop.

But ideally, you would want to keep the minification.

Edit:

you can do, 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).

Also if you see node-sass in your devDependencies, remove that as well with

npm remove -D node-sass and you should be good to go. Cheers!

Sign up to request clarification or add additional context in comments.

7 Comments

I ran tns plugin remove nativescript-dev-sass in the console. I got Plugin "nativescript-dev-sass" is not installed. Yet, I've got some scss files in my project which were generated when creating the project.
Might this be a part of the nativescript-dev-webpack?
can you check the hooks folder once? there could be some dev-sass remnants there
also to be on safer side, check your devDependencies in package.json, see if there is nativescript-dev-sass, because it is not like other plugins of nativescript.
So my suspicion was right. Now you do, npm remove -D nativescript-dev-sass and you remove those dev-sass files which are in hooks folder. Also if you see node-sass in your devDependencies, remove that as well with npm remove -D node-sass and you should be good to go. Cheers!
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.