Skip to content

Commit 15c0eb0

Browse files
authored
fix(plugin-vue): suppress warnings for non-recognized pseudo selectors form lightningcss (#521)
1 parent 2135c84 commit 15c0eb0

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

packages/plugin-vue/src/index.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,20 @@ export default function vuePlugin(rawOptions: Options = {}): Plugin<Api> {
277277
!config.isProduction
278278
),
279279
}
280+
281+
// #507 suppress warnings for non-recognized pseudo selectors from lightningcss
282+
const _warn = config.logger.warn
283+
config.logger.warn = (...args) => {
284+
const msg = args[0]
285+
if (
286+
msg.match(
287+
/\[lightningcss\] '(deep|slotted|global)' is not recognized as a valid pseudo-/,
288+
)
289+
) {
290+
return
291+
}
292+
_warn(...args)
293+
}
280294
},
281295

282296
configureServer(server) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy