Skip to content

Commit

Permalink
Improve comments on how the static build compilation
Browse files Browse the repository at this point in the history
works differently.
  • Loading branch information
matthewp committed Jan 24, 2022
1 parent c3b4279 commit 2899856
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/astro/src/vite-plugin-astro/compile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,9 @@ async function compile(config: AstroConfig, filename: string, source: string, vi
experimentalStaticExtraction: config.buildOptions.experimentalStaticBuild,
// TODO add experimental flag here
preprocessStyle: async (value: string, attrs: Record<string, string>) => {
// When using this flag CSS because <link> and therefore goes through Vite's
// CSS pipeline. We don't need to transform here.
// When using this flag CSS is added via <link> and therefore goes
// through Vite's CSS pipeline. We don't need to transform here, it will be
// transformed on CSS requests.
if (config.buildOptions.experimentalStaticBuild) {
return { code: value };
}
Expand Down

0 comments on commit 2899856

Please sign in to comment.