joeldenning / coexisting-vue-microfrontends

A repo showing separate vue apps coexisting as microfrontends with single-spa
http://coexisting-vue-microfrontends.surge.sh/
MIT License
614 stars 143 forks source link

what if we use third-party ui library like element-ui,and has to import seperate css file #76

Closed j-joker closed 3 years ago

j-joker commented 3 years ago

can we just link the css file in the load function and unlink the file in the unmount hook function?

joeldenning commented 3 years ago

You can load CSS files in the loading function, or in the bootstrap lifecycle function. Unmounting the <link> from the DOM during unmount cleans up memory and avoids collisions.

j-joker commented 3 years ago

Thank you for answering my question