Skip to content

How to use mini-css-extract-plugin / ExposeRuntimeCssAssetsPlugin only during production? #13

Answered by joeldenning
PieterBoeren asked this question in Q&A
Discussion options

You must be logged in to vote

This discussion seems more related to single-spa-css than to create-single-spa, since create-single-spa doesn't use single-spa-css yet (although I'd like it to be added). I'm transferring this to the single-spa-css repo.

Generally I prefer keeping functionality the same for development vs production where possible. So when I use single-spa-css I just use it for both development and production. This is for two reasons:

  1. Portable build artifacts - if a build artifact can be used in development, test environments, and production, then you only have to build once rather than once per environment, and can use import-map-overrides between environments to load any bundles.
  2. Ability to reproduce i…

Replies: 0 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by PieterBoeren
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants