1

While generating document form yuidoc I want to ignore downloaded javascript libraries inside lib folder of my project. How can I place that into ignore list I tried "ignorePaths": [ "./lib" ], "ignorePaths": [ "./lib/*.js" ], "ignorePaths": [ "lib" ]

still it's compiles my javascript library files.

Suraz
  • 1,119
  • 7
  • 10

2 Answers2

1

Instead, try using the exclude option as discussed here https://github.com/yui/yuidoc/issues/5

"exclude" : ["lib"]

slolife
  • 19,520
  • 20
  • 78
  • 121
  • 4
    The `exclude` option seems to take a string not an array as its value. YUIDoc calls `string.split` to get the paths. – RunnerRick Nov 11 '13 at 20:58
  • From the official doc: "Specify a comma separated list of names you want to `exclude` from parses when YUIDoc recurses the source tree." – CedX Jun 20 '14 at 16:38
0

I'm adding an answer with a little more detail since I ran into this problem yesterday and it could be helpful to someone else.

As @slolife mentioned, you should be using "exclude".

The value for "exclude" needs to be a String of comma separated directories (not Array). This can be done via your JSON config file as one of the "options" or as a command-line argument.

Single Directory Examples

JSON Config File

{
    "name": "My Project",
    "options": {
        "exclude": "lib"
    }
}

Command-line

yuidoc . -x "lib"


Multiple Directories Examples

NOTE: NO spaces between directories in the list

JSON Config File

{
    "name": "My Project",
    "options": {
        "exclude": "lib,lib2"
    }
}

Command-line

yuidoc . -x "lib","lib2"

Reference: http://yui.github.io/yuidoc/args/index.html

Mycah
  • 4,602
  • 5
  • 24
  • 32