Search code examples
javascriptdocumentationesdoc

ESDoc: Ignoring Specific File


While trying to document a JavaScript file, an error occurred. To solve this issue, the strategy will follow a different direction. We aim to ignore the cause of the issue since the code do what we want.

For this project, we are using the ESDoc for our JavaScript documentation generation. However, as said before, the ESDoc parser behaviour is not admitting one of our files. By addressing the Features of ESDoc we found no trivial solution to ignore some foo.js file on a specific directory.

So our question is:

Is there some way to tell ESDoc to ignore a specific file or directory?

We research over the issue and found nothing. Please, do not misinterpret our request over a solution, we really did an overlook on the available features.

Thank you for your time.


Solution

  • Maybe:

    {
      "source": ".",
      "includes": ["\\.js$"],
      "excludes": ["(node_modules|docs|test|foo.js)"],
      "destination": "./docs",
      "plugins": [{"name": "esdoc-standard-plugin"}]
    }
    

    for exclude node_modules, docs, test dirs ..... and foo.js file.

    Or

    {
      "source": ".",
      "includes": ["\\.js$"],
      "excludes": ["foo.js"],
      "destination": "./docs",
      "plugins": [{"name": "esdoc-standard-plugin"}]
    }
    

    Only for file foo.js

    I've done in this way.