hrgdavor / jscadui

MIT License
30 stars 9 forks source link

allow module that exports only the function #77

Closed hrgdavor closed 9 months ago

hrgdavor commented 9 months ago

as discussed here https://github.com/jscad/OpenJSCAD.org/issues/1318#issuecomment-1896245210

this script does not work and it should to match openjscad.xyz

module.exports=function main(){return require('@jscad/modeling').primitives.sphere({radius: 50})}
hrgdavor commented 9 months ago

@Hermann-SW this is now fixed

https://jscad.app#data:application/javascript;base64,bW9kdWxlLmV4cG9ydHM9ZnVuY3Rpb24gbWFpbigpe3JldHVybiByZXF1aXJlKCdAanNjYWQvbW9kZWxpbmcnKS5wcmltaXRpdmVzLnNwaGVyZSh7cmFkaXVzOiA1MH0pfQ==

Hermann-SW commented 9 months ago

@hrgdavor I tested under Debian based 64bit Raspberry Pi OS. Works for firefox ! Does not work (empty display) for chromium-browser :-(

chromium-browser console: https://stamm-wilbrandt.de/images/browser_console_77.png

hrgdavor commented 9 months ago

@Hermann-SW that is strange, it works on my PC, chrome and vivaldi browser. could it be cahce ? try CTRL+F5 ?

Hermann-SW commented 9 months ago

@hrgdavor The browser is not chrome, that does not exist for ARM. I pressed CTRL+F5 and recorded with peek screenrecorder. After quite some activity, no display: https://stamm-wilbrandt.de/videos/Peek_2024-01-17_22-04.gif

hrgdavor commented 9 months ago

@Hermann-SW it is hard to tell what could be the issue.

Do other scripts work on that chromium in jscad.app ?. I am interested if the issue is data:url for that chromium or the script itself ?

Hermann-SW commented 9 months ago

@hrgdavor other scripts work in chromium browser. And the small script in editor without data uri does not work either in chromium. Perhaps one of your developers has access to a Raspberry Pi SBC and can test with chromium.

hrgdavor commented 9 months ago

Perhaps one of your developers has access to a Raspberry Pi SBC and can test with chromium.

Sadly, I doubt. me a @platypii are active here, and we both contribute to jscad along with one more developer taht is main dev of jscad.

If you want, come to our discord, and we could see if we can get to bottom of this. Maybe even some remote desktop access.