Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I feel stupid asking this question, but isn't the browser that parses css? i understand minifying css, but what does parcel's css parsing refer to?


To do the job of minifying, this minifyer first reads the CSS file into an internal datastructure. That process is called parsing.

All the minifying operations are done on that internal datastructure.

Then it writes it out again into a textfile, ready for the browser to parse it again - hopefully the minifying step made it a bit easier for the browser to parse this minified CSS.


It parses the css so it can improve the minification, for example converting 'margin: 4px 4px 4px 4px' into 'margin:4px'


For packages that have images and css, it reads css and extracts image files to be bundled.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: