documentationjs / documentationjs/documentation

Option to automatically group files in modules

Open
#234 6 comments 8 reactions 0 assignees View on GitHub
enhancement
Dominant language
JavaScript
Stars
5.8k
Forks
481
PR merge metrics
No merged PRs in 30d

Description

I'm a big fan on inferring documentation properties from code: I'm using _documentation.js_ mainly because it allows me to omit the ‘boring’ parts of doc comments by using Flow types. Similarly, since my code uses CommonJS/ES2015 import/exports, I've never seen the value in manually adding JSDoc's `@module` tag to all my files.

Thus, I want to suggest a new option for _documentation.js_: Infer modules from file names.

Let's say I have a `src/foo/bar.js`. Its module name is the same as the name I can `require()` or `import` it with, i.e. `foo/bar`.

I'm not sure what your plans for handling modules/grouping documentation items is in general, but for larger projects, I'd like to see a _documentation.js_ theme that lists entries in a tree instead of a flat list.

Ideally, this would also allow me to see which items are exported from a module.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.