-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Labels
Description
Describe the bug
Recently, I found that my package doesn't work well. Because of repeatedly importing the same module, It occurs an undefined reference error. Code likes:
import A from 'm.js'
import B from 'm.js'
console.log(A)
console.log(B) // undefinedInput code
import A from 'm.js'
import B from 'm.js'
console.log(A)
console.log(B) // undefinedConfig
{
"jsc": {
"parser": {
"syntax": "typescript",
"dynamicImport": true
},
"minify": {
"compress": true,
"mangle": true
}
},
"env": {
"targets": {
"chrome": "80"
},
"mode": "usage",
"coreJs": "3"
},
"minify": true
}Link to the code that reproduces this issue
SWC Info output
No response
Expected behavior
B is not undefined
Actual behavior
No response
Version
1.15.3
Additional context
No response