fix imports with alias from $ (#4332)
This commit is contained in:
parent
4c4c59bf04
commit
a454b705a8
@ -111,9 +111,9 @@ def load_dynamic_serializer():
|
|||||||
if line.startswith("import "):
|
if line.startswith("import "):
|
||||||
if 'from "$/' in line or 'from "/' in line:
|
if 'from "$/' in line or 'from "/' in line:
|
||||||
module_code_lines[ix] = (
|
module_code_lines[ix] = (
|
||||||
line.replace("import ", "const ", 1).replace(
|
line.replace("import ", "const ", 1)
|
||||||
" from ", " = window['__reflex'][", 1
|
.replace(" as ", ": ")
|
||||||
)
|
.replace(" from ", " = window['__reflex'][", 1)
|
||||||
+ "]"
|
+ "]"
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user