react-toolbox-themr icon indicating copy to clipboard operation
react-toolbox-themr copied to clipboard

Outputting Minified Obfuscated Styles

Open FullstackJack opened this issue 7 years ago • 5 comments

Perhaps I'm not using the tool correctly or perhaps I expected something different, but when I follow the setup guide in the README, the tool outputs the theme.css and theme.js minified and obfuscated. Shortened for brevity.

theme.css

._3nrqp{-webkit-box-align:center;-ms-flex-align:center;align-items:center;...```

theme.js

module.exports={"RTDialog":{"wrapper":"_3nrqp","dialog":"_3lw90","active":"_3ea_1",

Would this tool be picking up the postcss.config.js file in my project root?

FullstackJack avatar Mar 08 '17 17:03 FullstackJack

Mine, too. Thought that was intentional.

csalvato avatar Mar 15 '17 01:03 csalvato

I've resorted to copying the source styles individually per component, but that's less than ideal and easy to screw up.

FullstackJack avatar Mar 15 '17 01:03 FullstackJack

Is there an option or something to turn off obfuscation?

silenzium avatar Mar 24 '17 10:03 silenzium

Undocumented config option 'fixed' worked for me. set 'fixed' to true, output should no longer be obfuscated.

"reactToolBox":{
  "include":[
      "DATE_PICKER"
 ],
"fixed":true

Cheers,

Galderak avatar May 16 '17 22:05 Galderak

Wow, this is great! I think that option should be documented. In fact, I think it should be the default option, and if it does not minify also, even better (right now that option only prevents obfuscation). Then there should be an option to request output to be obfuscated and or minified, not the other way around.

gnapse avatar Jun 15 '17 14:06 gnapse