-
Notifications
You must be signed in to change notification settings - Fork 701
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
How does exclude work ? #170
Comments
Hi, I'm on the same boat as @ocombe. |
Hi, got the same problem with exclude trying this: |
Same issue here. Also how to configure multiple exclusions? |
I'm having the exact same issue. I want to ignore spec files. "" is not helpful at all without an example of what a "pattern" is. |
Hi, you can use for example: The syntax seems to be |
Seen here ( typedoc/src/lib/application.ts Line 253 in 53bb762
|
Changing the docs to say that patterns are "standard" minimatch patterns would be very helpful. |
You are welcome to submit a PR improving the docs. |
I know this has been closed but I think that what would be interesting to know in the docs is what is given to minimatch for testing. If you pass the whole path to the file, the pattern will be different than if you are passing what comes after |
Then there is no way to exclude an entire directory? |
@Zeioth yup you can via the pattern.
To exclude the |
I managed to exclude several folders, HTH |
For whatever reason this only worked for me when I escaped the path like so: |
Just to add some info to this, if you use typedoc with a javascript config file
module.exports = {
out: './docs/dist/api/',
readme: 'none',
includes: './',
exclude: [
'**/__tests__/**/*',
'**/__test_utils__/**/*',
'**/__fixtures__/**/*',
'**/testsuite/**/*'
],
mode: 'file',
excludeExternals: true,
excludeNotExported: true,
excludePrivate: true
}; |
This exclude is not working: module.exports = {
mode: 'file',
out: 'dist/typedoc',
theme: 'default',
ignoreCompilerErrors: true,
excludePrivate: true,
excludeNotExported: 'true',
excludeExternals: true,
target: 'ES5',
moduleResolution: 'node',
preserveConstEnums: 'true',
stripInternal: 'true',
suppressExcessPropertyErrors: 'true',
suppressImplicitAnyIndexErrors: 'true',
module: 'commonjs',
readme: 'README.md',
exclude: [
'**/*.spec.ts',
'**/*.module.ts',
],
}; I don't want to render *.module.ts files because they just import and export things, they don't add nothing to the documentation. Why the exclude patter is not working? |
A lot of users in this thread are actually using shell globs. I'm finding this to not work (shell does not expand the glob with single quotes): Using the shell glob doesn't work either: If glob patterns are meant to work, it's broken. |
@hoten it actually supports Minimatch globs. Declarations should be handled differently though. There is the |
Thanks @aciccarello. Yeah, some of us are having issues with declaration files. #820 is the relevant issue. |
It is also possible to specify multiple excludes in cli by specifying several exclude arguments: |
is it possible to display specific comments only using typedoc? |
It is not working at all. |
you can use it like this,
|
Hello,
I use the command line:
typedoc --options typedoc.json --exclude *.spec.ts src/app/
But it generates documentation for my file "src/app/app.spec.ts".
Shouldn't it be excluded ?
The text was updated successfully, but these errors were encountered: