esm: make enhancements to example loader fixture#32646
esm: make enhancements to example loader fixture#32646DerekNonGeneric wants to merge 1 commit intonodejs:mainfrom DerekNonGeneric:example-loader-typings
Conversation
* Add JSDoc typings to function boundaries * Remove import of URL & process as they are unnecessary * Update bare-specifier check to match language used in error * Improve accuracy of hook's thrown error message * Move destructuring assignment of default to within function Refs: #31303
|
Fixtures aren't example code for people to follow, they're blobs of code used in our tests. Items in |
|
This strikes me as more of an integration test of the hooks. |
|
For addons.md, we have code that extracts the code samples and makes sure they all compile. Perhaps we could do something similar for esm.md? |
|
According to the documentation style guide, this work should be located elsewhere. node/doc/guides/doc-style-guide.md Lines 34 to 37 in 49db211 Unless this test fixture is supposed to serve as some sort of poor-man's integration test of the hooks, I would be inclined to move this example out of this directory and into the location specified by the documentation style guide, however, this directory ( |
8ae28ff to
2935f72
Compare
|
The loader API has changed a lot since this PR was opened, it seems this PR no longer applies. Closing. |
Refs: #31303
/cc @nodejs/modules-active-members
Checklist