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

update docs to show that ES modules can be used with root hook plugins #4310

Closed
boneskull opened this issue Jun 3, 2020 · 3 comments
Closed
Assignees
Labels
area: documentation anything involving docs or mochajs.org
Milestone

Comments

@boneskull
Copy link
Member

boneskull commented Jun 3, 2020

~~With #4244 landing and #4304 thereafter, we should ensure that root hook plugins can be used with ES modules; e.g. export const mochaHooks = {..}

I'll take care of this. Should probably land for v8, as it would be confusing if it didn't. ~~

It does work, and there are even tests for it.

What's missing is docs. I'll get to that.

@boneskull boneskull added this to the v8.0.0 milestone Jun 3, 2020
@boneskull boneskull self-assigned this Jun 3, 2020
@boneskull
Copy link
Member Author

Actually I think it does work. wow, good job

@boneskull boneskull removed this from the v8.0.0 milestone Jun 3, 2020
@boneskull boneskull changed the title support ESM modules for rootHooks update docs to show that ES modules can be used with root hook plugins Jun 3, 2020
@boneskull boneskull reopened this Jun 3, 2020
@boneskull boneskull added this to the v8.0.0 milestone Jun 3, 2020
@boneskull boneskull added the area: documentation anything involving docs or mochajs.org label Jun 3, 2020
@boneskull
Copy link
Member Author

Hmm, I don't like the failure mode when --require some-esm.js (instead of .mjs). The error is unrelated and unhelpful

@boneskull
Copy link
Member Author

closed via #4311

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: documentation anything involving docs or mochajs.org
Projects
None yet
Development

No branches or pull requests

1 participant