Hi, I'm facing this issue with using JS-style comments.
this happens when I comment on a line just at the end of a CSS property, in the same line right after ;
this would break styles below it after building the project.
background-color: hsl(
0,
0%,
95%
); // this comment would break all styles below it
It's working fine in development mode as probably babel-plugin-styled-components wouldn't be used in the development mode, I tested using both in CRA and Snowpack.
and also it would work fine if the comment is on a new line or at the end of a css decleration scope, like this:
.some-class {
background-color: hsl(
0,
0%,
95%
);
}// from react-select disabled state background
Hi, I'm facing this issue with using JS-style comments. this happens when I comment on a line just at the end of a CSS property, in the same line right after
;
this would break styles below it after building the project.It's working fine in
development
mode as probablybabel-plugin-styled-components
wouldn't be used in the development mode, I tested using both inCRA
andSnowpack
.and also it would work fine if the comment is on a new line or at the end of a css decleration scope, like this:
I provided a reproducible example here: https://github.com/mhsattarian/babel-plugin-styled-components-comment-issue
build the project and see how text on the screens have no color assigned.