herberttn / bytenode-webpack-plugin

Compile JavaScript into bytecode using bytenode
MIT License
105 stars 27 forks source link

Wrong path to ".jsc" in sub_window #24

Open mcjambi opened 1 year ago

mcjambi commented 1 year ago

i have a screenplay folder and that has a renderer, preload and many assets. All works normally! After adding your plugin, my code break all.

After 15 minutes of researching, i find out: Error in console: "Uncaught Error: Cannot find module './sub_window.compiled.jsc'" Cause by: My index.html has included sub_window.js, in subwindow.js include "./sub_window.compiled.jsc", but actually it must be "../sub_window.compiled.jsc" because it is included in sub_window/index.html

Right now i have to modified my code after run built. Just adding a DOT in a file :D

Screenshot 2023-03-03 104845

herberttn commented 1 year ago

@mcjambi can you make a reproduction repository so I can try to fix it?

herberttn commented 1 year ago

@mcjambi does this still happen? If so, can you create a reproduction repo?

iamisti commented 10 months ago

im getting the same error but I have no idea how to fix it. Somehow it does not find the jsc files. It's there in the folder, but the path might be wrong. How do align/change what path it's looking for to find the jsc files?

iamisti commented 10 months ago

i have a screenplay folder and that has a renderer, preload and many assets. All works normally! After adding your plugin, my code break all.

After 15 minutes of researching, i find out: Error in console: "Uncaught Error: Cannot find module './sub_window.compiled.jsc'" Cause by: My index.html has included sub_window.js, in subwindow.js include "./sub_window.compiled.jsc", but actually it must be "../sub_window.compiled.jsc" because it is included in sub_window/index.html

Right now i have to modified my code after run built. Just adding a DOT in a file :D

Screenshot 2023-03-03 104845

can you please show me what you did? I can't figure it out. I have the same issue as you described.