documentationjs / documentationjs/documentation

How to exclude directories?

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

Description

* What version of documentation.js are you using?: 5.3.2
* How are you running documentation.js (on the CLI, Node.js API, Grunt, other?): CLI

On a project, we have fairly gnarly setup of multiple modules in a monorepo each can contain a `node_modules` and `build` directory.

By default I'd like to include all `.mjs` files in the docs and exclude `node_modules` and `build` directories.

What is the best approach for including / excluding files for a package structure like?

```
- packages/
- module-one/
- index.mjs
- build/
- build.js
- node_modules/
- module-two/
- index.mjs
- other-dir/
- example.mjs
```
At the moment I just got mjs building with:

```
documentation serve packages/**/* --require-extension mjs --parse-extension mjs
```

Which is obviously including `build` and `node_modules`

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.