-
-
Notifications
You must be signed in to change notification settings - Fork 6.1k
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
HMR error: Cannot access '...' before initialization (happend on <script setup lang="ts"> ..... </script>) #4430
Comments
you could fix this by removing the circular dependency. |
yeah! Remoing the circualr dependency will be right. But I have a question:Is the browser es6 import cause no circular dependency? |
This is not a Vite bug. ESM does support circular dependency, but it still has limitations - you can't eagerly access imported bindings of a file that's later in the import chain:
Here |
Describe the bug
at store.ts:4 " with first open browser.
Reproduction
https:/china-bin/vite-script-setup-ts-import-bug
System Info
Used Package Manager
yarn
Logs
No response
Validations
The text was updated successfully, but these errors were encountered: