Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

fix(stencil): ensure Stencil CSS imports include &inline query param - #39

Closed
hoanle0126 wants to merge 1 commit into
webdriverio:mainfrom
hoanle0126:fix/stencil-component-starter-30
Closed

hoanle0126 wants to merge 1 commit into
webdriverio:mainfrom
hoanle0126:fix/stencil-component-starter-30

Conversation

@hoanle0126

Copy link
Copy Markdown

When Stencil transpiles components without &encapsulation=shadow (or on Windows where path.resolve emits backslashes), Vite 5+ rejects the .css?tag=... default import unless &inline is appended (The requested module '/src/components/my-component/my-component.css?tag=my-component' does not provide an export named 'default').

This adds a small Vite transform plugin in stencil-component-starter/wdio.conf.ts that normalizes .css?tag= imports to forward-slash /@fs/...&inline specifiers (and wraps the CSS string in a function when newer @stencil/core versions invoke the style import as a function).

Fixes #30

@hoanle0126 hoanle0126 closed this Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Problem with Stencil

1 participant