Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: @linaria/rollup compliant vite #763

Merged
merged 1 commit into from Jun 6, 2021
Merged

fix: @linaria/rollup compliant vite #763

merged 1 commit into from Jun 6, 2021

Conversation

wmzy
Copy link
Contributor

@wmzy wmzy commented May 28, 2021

Motivation

@linaria/rollup inject the css file with a real file path, but the css flie not exist in file system.
And vite rewrite the absolute path with a relative path, so vite server could not find the the css file from file system and @linaria/rollup could not find it from cssLookup object.

I add a @linaria: prefix to css filename so that rollup and vite see it as a virtrul file.

Summary

Make it work for vite.

Test plan

@Anber Anber merged commit 3966dcf into callstack:master Jun 6, 2021
@Anber
Copy link
Collaborator

Anber commented Jun 6, 2021

Thank you @wmzy!

@Anber
Copy link
Collaborator

Anber commented Jun 10, 2021

Hi @wmzy,

There is a report about regression after this PR #778

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.

None yet

2 participants