nativescript-dev-webpack icon indicating copy to clipboard operation
nativescript-dev-webpack copied to clipboard

Uglify.js: CSS styles for element selectors are not applied when element is registered (e.g. CardView)

Open NickIliev opened this issue 6 years ago • 0 comments

Styles of the following type (element selector) are not applied when building with uglify

CardView {
    background-color: slateblue;
}

CardView > GridLayout {
    background-color: green;
}

The cardview element (from nativescript-cardview) is registered via Angular's registerElement

Then we are building with the following command (Webpack enabled by default)

 tns run android --env.uglify

As a result, the above CSS won't be applied. Works as expected when the uglify flag is not provided. Test project demonstrating the above can be found [here](Test project demonstrating the above can be found here

NickIliev avatar May 27 '19 06:05 NickIliev