-
Notifications
You must be signed in to change notification settings - Fork 44
Refactor module documentation #539
Comments
Thank you for creating this summary! I agree that the modules documentation needs some love, but I'm currently not in favor of merging the CJS and ESM docs. One is an experimental API, the other one is stable, and both are quite meaty. Don't get me wrong, I think some sort of restructuring needs to happen, but merging those seems like a bad idea as of right now. When I get a chance, I will try to determine what my opinion would be on the best course of action to take. |
I think he's proposing four separate top-level pages, similar to what I had suggested in nodejs/node#33512 (comment). The only other part was that I suggested moving the source maps section onto the Debugger page or onto its own page, since it's not really part of modules. |
I like the four page separation. Perhaps |
I somehow missed notifications on this issue and didn't realize that there were alternatives being proposed. @aduh95 made the PR before I could dedicate any amount of time looking into what I think would be best. I still stand by nodejs/node#34748 (review), but also wouldn't consider it a blocker, so I've pre-approved that PR. I would wait on @guybedford and @GeoffreyBooth before landing though. |
The `module` core module is available for both CJS and ESM users, it deserves its own page. PR-URL: #34747 Refs: nodejs/modules#539 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539
The `module` core module is available for both CJS and ESM users, it deserves its own page. PR-URL: #34747 Refs: nodejs/modules#539 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]>
The `module` core module is available for both CJS and ESM users, it deserves its own page. PR-URL: #34747 Refs: nodejs/modules#539 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539 PR-URL: #34663 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Rich Trott <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539 PR-URL: #34663 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Rich Trott <[email protected]>
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. Refs: nodejs/modules#539
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. * Move Enabling section * Update Enabling section * Remove -u flag * Package scopes do not carry through `node_modules` folders Refs: nodejs/modules#539 Co-authored-by: Geoffrey Booth <[email protected]>> Co-authored-by: Guy Bedford <[email protected]> PR-URL: #34748 Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Ruy Adorno <[email protected]>
Landed in core. |
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. * Move Enabling section * Update Enabling section * Remove -u flag * Package scopes do not carry through `node_modules` folders Refs: nodejs/modules#539 Co-authored-by: Geoffrey Booth <[email protected]>> Co-authored-by: Guy Bedford <[email protected]> PR-URL: #34748 Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Ruy Adorno <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539 PR-URL: nodejs#34663 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Rich Trott <[email protected]>
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. * Move Enabling section * Update Enabling section * Remove -u flag * Package scopes do not carry through `node_modules` folders Refs: nodejs/modules#539 Co-authored-by: Geoffrey Booth <[email protected]>> Co-authored-by: Guy Bedford <[email protected]> PR-URL: nodejs#34748 Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Ruy Adorno <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539 Backport-PR-URL: #35757 PR-URL: #34663 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Rich Trott <[email protected]>
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. * Move Enabling section * Update Enabling section * Remove -u flag * Package scopes do not carry through `node_modules` folders Refs: nodejs/modules#539 Co-authored-by: Geoffrey Booth <[email protected]>> Co-authored-by: Guy Bedford <[email protected]> Backport-PR-URL: #35757 PR-URL: #34748 Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Ruy Adorno <[email protected]>
The `module` core module is available for both CJS and ESM users, it deserves its own page. PR-URL: #34747 Refs: nodejs/modules#539 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]>
Using a "Modules:" prefix groups all the related pages together when using alphabetical order. Refs: nodejs/modules#539 Backport-PR-URL: #35757 PR-URL: #34663 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Rich Trott <[email protected]>
This part of the docs aims to contain documentation regarding package configuration that covers both ESM and CJS realms. * Move Enabling section * Update Enabling section * Remove -u flag * Package scopes do not carry through `node_modules` folders Refs: nodejs/modules#539 Co-authored-by: Geoffrey Booth <[email protected]>> Co-authored-by: Guy Bedford <[email protected]> Backport-PR-URL: #35757 PR-URL: #34748 Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]> Reviewed-By: Guy Bedford <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Ruy Adorno <[email protected]>
The `module` core module is available for both CJS and ESM users, it deserves its own page. PR-URL: #34747 Refs: nodejs/modules#539 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]>
There are a few issues open from users complaining about the current state of the docs:
I have two open PRs (nodejs/node#32970 and nodejs/node#33512) on node's repo trying to find another angle, and I'd like to thank @guybedford, @GeoffreyBooth and others who reviewed them. However, both approaches have failed and a discussion have initiated about a third attempt.
I think Node.js would benefit from getting more feedback before committing to a structure for this part of the docs, and this WG felt the right place to do so.
Currently there are two pages that deal with modules:
However there is no apparent logic on where a user can find documentation about features which a neither CJS nor ESM specific (
package.json
fields, package authoring, SourceMap support, themodule
core module, …).In nodejs/node#33512 (comment), it was suggested that we could use something like:
Package authoringconfigurationPackagesmodule
core moduleAPI (including Source map v3 docs)Modules: Source map v3 support (or could be moved to Debugger page)The
Modules:
prefix is there to make sure those entries will appear next to one another in the TOC. What are your thoughts?EDIT: I've included the suggestions from this thread (there are 3 comments at the time of edit).
The text was updated successfully, but these errors were encountered: