fix: support postcss lang (#1948)

This commit is contained in:
Nate Moore 2021-11-22 11:40:11 -06:00 committed by GitHub
parent f37c7ad2ad
commit 22dd6bf6d6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
'astro': patch
---
Support `lang="postcss"` in addition to `lang="pcss"`

View file

@ -4,7 +4,7 @@ import path from 'path';
import { viteifyURL } from '../util.js'; import { viteifyURL } from '../util.js';
// https://vitejs.dev/guide/features.html#css-pre-processors // https://vitejs.dev/guide/features.html#css-pre-processors
export const STYLE_EXTENSIONS = new Set(['.css', '.pcss', '.scss', '.sass', '.styl', '.stylus', '.less']); export const STYLE_EXTENSIONS = new Set(['.css', '.pcss', '.postcss', '.scss', '.sass', '.styl', '.stylus', '.less']);
/** find unloaded styles */ /** find unloaded styles */
export function getStylesForURL(filePath: URL, viteServer: vite.ViteDevServer): Set<string> { export function getStylesForURL(filePath: URL, viteServer: vite.ViteDevServer): Set<string> {