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: virtual bundle for webpack #446

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

BobbieGoede
Copy link
Member

More refactoring! This narrows the type returned by resolved options and changes the way default values are applied to the user input.

More changes have been made to improve type inference/safety and I have replaced async fs function calls with synchronous calls.

I hope the tests cover enough to catch if I made any mistakes... 🫣

@BobbieGoede BobbieGoede added Type: Performance Includes performance fixes Type: Refactoring A code change that neither fixes a bug nor adds a feature Package: unplugin-vue-i18n labels Mar 9, 2025
@BobbieGoede BobbieGoede requested a review from kazupon March 9, 2025 16:31
@BobbieGoede BobbieGoede self-assigned this Mar 9, 2025
...opts,
filename,
sourceMap,
jit,
jit: true,
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kazupon
While refactoring it seemed like all option passing eventually resulted in jit: true being passed, is this correct?

@BobbieGoede BobbieGoede changed the title refactor: option defaults, type narrowing and sync fs fix: virtual bundle for webpack Mar 9, 2025
@BobbieGoede
Copy link
Member Author

I did some more refactoring on this branch, I think the virtual bundle/resource didn't work for webpack earlier? 🤔 It now works with these changes, I have re-enabled the bundle-import tests for webpack and rspack.

Unfortunately, reload on locale file change only works for vite and webpack, not sure how to get that working for rspack.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: unplugin-vue-i18n Type: Performance Includes performance fixes Type: Refactoring A code change that neither fixes a bug nor adds a feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant