Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support mjs loading #13

Merged
merged 2 commits into from
Feb 5, 2024
Merged

Support mjs loading #13

merged 2 commits into from
Feb 5, 2024

Conversation

STRd6
Copy link
Collaborator

@STRd6 STRd6 commented Dec 11, 2023

First step on generating mjs from Hera.

This may be helpful to update our loaders for node v18.19 and v20

@STRd6
Copy link
Collaborator Author

STRd6 commented Dec 11, 2023

Inside modImport I created a temp file rather than use a data url for the import because I couldn't figure out how to have a data url also import machine.js correctly.

Copy link
Collaborator

@edemaine edemaine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Nice how most of the code was already there for TypeScript purposes. 🙂

I'm not quite sure how machine.js works (is it supposed to already exist when calling modImport?), but I imagine you could replace it with a URL in the same way you already do a .replace('"machine.js"'.

@STRd6 STRd6 merged commit d11b54b into main Feb 5, 2024
4 checks passed
@STRd6 STRd6 deleted the mjs branch February 5, 2024 03:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants