Skip to content
This repository has been archived by the owner on Mar 14, 2024. It is now read-only.

Switch to type:module in package.json #2582

Closed
samthor opened this issue Apr 14, 2020 · 6 comments
Closed

Switch to type:module in package.json #2582

samthor opened this issue Apr 14, 2020 · 6 comments
Labels
accepted **Should be used by Eng team only**: Use this to tell the stalebot to keep a bug or PR open. feature request New feature or request stale

Comments

@samthor
Copy link
Contributor

samthor commented Apr 14, 2020

Is your feature request related to a problem? Please describe.
It's hard to test parts of our build system, or have shared logic, since we can't import across different package types.

Describe the solution you'd like
Switch to ESM for the project. We should use "type": "module" in our 'package.json'.

Describe alternatives you've considered

  • We could have tests that run both CJS and ESM.
  • We could use Rollup's support, but this would only allow CJS => ESM, and not the other way around.
@samthor samthor added the feature request New feature or request label Apr 14, 2020
@robdodson
Copy link
Contributor

I'm cool with it if eleventy doesn't barf

@samthor
Copy link
Contributor Author

samthor commented Apr 14, 2020

There's only.... oh, 394 references to require(). How hard could the fix be?!

@samthor
Copy link
Contributor Author

samthor commented Apr 14, 2020

It seems like there's a workaround to make this work now but that it's officially unsupported. So maybe this goes on the backburner for a bit.

@stale
Copy link

stale bot commented May 14, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. To prevent his from happening, leave a comment.

@stale stale bot added the stale label May 14, 2020
@stale stale bot closed this as completed May 21, 2020
@samthor
Copy link
Contributor Author

samthor commented May 22, 2020 via email

@robdodson
Copy link
Contributor

@samthor you can add the accepted label to make the bot ignore stuff.

@samthor samthor added the accepted **Should be used by Eng team only**: Use this to tell the stalebot to keep a bug or PR open. label May 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
accepted **Should be used by Eng team only**: Use this to tell the stalebot to keep a bug or PR open. feature request New feature or request stale
Projects
None yet
Development

No branches or pull requests

2 participants