emscripten-core / emscripten-core/emscripten
MODULARIZE=1 adds code incompatible with MIN_NODE_VERSION=101900
Open
- Dominant language
- C++
- Stars
- 27.6k
- Forks
- 3.6k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 105
Description
Hi! Using emscripten v3.1.59, here are the two lines at the very beginning that should be fixed:
``` javascript
var _scriptName = typeof document != 'undefined' ? document.currentScript?.src : undefined;
if (typeof __filename != 'undefined') _scriptName ||= __filename;
```
The optional chaining operator (`?.`) and the logical OR assignment (`||=`) are only available in newer versions of NodeJS.
Those two lines are added by `-sMODULARIZE=1`.
Thanks a lot for the fix!
Kind regards,
Maurice
Contributor guide
Assessment
This issue has not been assessed yet.