X 归档 2024-03-02
Parcel also enables you to generate additional assets (eg css) from a macro. You can build your own statically extracted CSS-in-JS library in only a few lines of code. And since macros are just functions, you can create any API you want, eg accepting objects or theme values! 😲
Parcel 还支持从宏生成额外的资源(比如 css)。只需几行代码,你就能构建自己的静态提取式 CSS-in-JS 库。而且由于宏就是普通函数,你可以随心所欲地设计任何 API,比如接受对象或主题值!😲

