|
1 |
| -# grunt-documentation |
2 |
| - |
3 |
| -[](https://circleci.com/gh/documentationjs/grunt-documentation/tree/master) |
4 |
| -[](https://greenkeeper.io/) |
5 |
| - |
6 |
| -Use [Grunt](http://gruntjs.com/) with |
7 |
| -[documentation](https://github.com/documentationjs/documentation) |
8 |
| -to generate great documentation for your JavaScript projects. |
9 |
| - |
10 |
| -## Getting Started |
11 |
| -This plugin requires Grunt `>=0.4.0` |
12 |
| - |
13 |
| -If you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command: |
14 |
| - |
15 |
| -```shell |
16 |
| -npm install grunt-documentation --save-dev |
17 |
| -``` |
18 |
| - |
19 |
| -Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript: |
20 |
| - |
21 |
| -```js |
22 |
| -grunt.loadNpmTasks('grunt-documentation'); |
23 |
| -``` |
24 |
| - |
25 |
| -## The "documentation" task |
26 |
| - |
27 |
| -### Overview |
28 |
| -In your project's Gruntfile, add a section named `documentation` to the data object passed into `grunt.initConfig()`. |
29 |
| - |
30 |
| -```js |
31 |
| -grunt.initConfig({ |
32 |
| - documentation: { |
33 |
| - default: { |
34 |
| - files: [{ |
35 |
| - "expand": true, |
36 |
| - "cwd": "src", |
37 |
| - "src": ["**/*.js"] |
38 |
| - }], |
39 |
| - options: { |
40 |
| - destination: "docs" |
41 |
| - } |
42 |
| - }, |
43 |
| - } |
44 |
| -}); |
45 |
| -``` |
46 |
| - |
47 |
| -### Options |
48 |
| - |
49 |
| -#### options.destination |
50 |
| -Type: `String` |
51 |
| - |
52 |
| -The destination folder for the generated docs. |
53 |
| - |
54 |
| -#### options.format |
55 |
| -Type: `String` |
56 |
| -Default value: `'html'` |
57 |
| - |
58 |
| -Either `'html'`, `'md'`, `'json'`, or `'docset'`. |
59 |
| - |
60 |
| -#### options.filename |
61 |
| -Type: `String` |
62 |
| - |
63 |
| -Custom filename for md or json output. |
64 |
| - |
65 |
| -#### options.access |
66 |
| -Type: `Array` |
67 |
| -Default value: `['protected', 'public', 'undefined']` |
68 |
| - |
69 |
| -Include only comments with a given access level, out of `private`, `protected`, `public` and `undefined`. By default, `public`, `protected` and `undefined` access levels are included. |
70 |
| - |
71 |
| -#### options.order |
72 |
| -Type: `Array` |
73 |
| -Default value: `[]` |
74 |
| - |
75 |
| -An array defining explicit sort order. |
76 |
| - |
77 |
| -#### options.theme |
78 |
| -Type: `String` |
79 |
| - |
80 |
| -Path to a custom theme. |
81 |
| - |
82 |
| -#### options.name |
83 |
| -Type: `String` |
84 |
| - |
85 |
| -A custom project name to display in the generated documentation. |
86 |
| - |
87 |
| -#### options.version |
88 |
| -Type: `String` |
89 |
| - |
90 |
| -A custom version string to display in the generated documentation. |
91 |
| - |
92 |
| -## Contributing |
93 |
| -In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint your code using [Grunt](http://gruntjs.com/). |
94 |
| - |
95 |
| -## Release History |
96 |
| - |
97 |
| -**v1.2.0** |
98 |
| -* new options: theme, name and version |
99 |
| -* now compatible with both 3.x and 4.x version of documentation |
100 |
| -* new theming demo |
101 |
| - |
102 |
| -**v1.1.2** |
103 |
| -* always use latest NPM packages |
104 |
| - |
105 |
| -**v1.1.1** |
106 |
| -* support Grunt 1.0 |
107 |
| - |
108 |
| -**v1.1.0** |
109 |
| -* new feature: `access` option to only include comments with a given access level, out of `private`, `protected`, `public` and `undefined` |
110 |
| -* new feature: `order` option to include user-defined sorting |
111 |
| - |
112 |
| -**v1.0.1** |
113 |
| -* store `md` format at right destination; fixes [issue #3](https://github.com/documentationjs/grunt-documentation/issues/3) |
114 |
| - |
115 |
| -**v1.0.0** |
116 |
| -* Transfered to documentationjs |
| 1 | +# grunt-documentation |
| 2 | + |
| 3 | +[](https://circleci.com/gh/documentationjs/grunt-documentation/tree/master) |
| 4 | +[](https://greenkeeper.io/) |
| 5 | + |
| 6 | +Use [Grunt](http://gruntjs.com/) with |
| 7 | +[documentation](https://github.com/documentationjs/documentation) |
| 8 | +to generate great documentation for your JavaScript projects. |
| 9 | + |
| 10 | +## Getting Started |
| 11 | +This plugin requires Grunt `>=0.4.0` |
| 12 | + |
| 13 | +If you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command: |
| 14 | + |
| 15 | +```shell |
| 16 | +npm install grunt-documentation --save-dev |
| 17 | +``` |
| 18 | + |
| 19 | +Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript: |
| 20 | + |
| 21 | +```js |
| 22 | +grunt.loadNpmTasks('grunt-documentation'); |
| 23 | +``` |
| 24 | + |
| 25 | +## The "documentation" task |
| 26 | + |
| 27 | +### Overview |
| 28 | +In your project's Gruntfile, add a section named `documentation` to the data object passed into `grunt.initConfig()`. |
| 29 | + |
| 30 | +```js |
| 31 | +grunt.initConfig({ |
| 32 | + documentation: { |
| 33 | + default: { |
| 34 | + files: [{ |
| 35 | + "expand": true, |
| 36 | + "cwd": "src", |
| 37 | + "src": ["**/*.js"] |
| 38 | + }], |
| 39 | + options: { |
| 40 | + destination: "docs" |
| 41 | + } |
| 42 | + }, |
| 43 | + } |
| 44 | +}); |
| 45 | +``` |
| 46 | + |
| 47 | +### Options |
| 48 | + |
| 49 | +#### options.destination |
| 50 | +Type: `String` |
| 51 | + |
| 52 | +The destination folder for the generated docs. |
| 53 | + |
| 54 | +#### options.format |
| 55 | +Type: `String` |
| 56 | +Default value: `'html'` |
| 57 | + |
| 58 | +Either `'html'`, `'md'`, `'json'`, or `'docset'`. |
| 59 | + |
| 60 | +#### options.filename |
| 61 | +Type: `String` |
| 62 | + |
| 63 | +Custom filename for md or json output. |
| 64 | + |
| 65 | +#### options.access |
| 66 | +Type: `Array` |
| 67 | +Default value: `['protected', 'public', 'undefined']` |
| 68 | + |
| 69 | +Include only comments with a given access level, out of `private`, `protected`, `public` and `undefined`. By default, `public`, `protected` and `undefined` access levels are included. |
| 70 | + |
| 71 | +#### options.order |
| 72 | +Type: `Array` |
| 73 | +Default value: `[]` |
| 74 | + |
| 75 | +An array defining explicit sort order. |
| 76 | + |
| 77 | +#### options.theme |
| 78 | +Type: `String` |
| 79 | + |
| 80 | +Path to a custom theme. |
| 81 | + |
| 82 | +#### options.name |
| 83 | +Type: `String` |
| 84 | + |
| 85 | +A custom project name to display in the generated documentation. |
| 86 | + |
| 87 | +#### options.version |
| 88 | +Type: `String` |
| 89 | + |
| 90 | +A custom version string to display in the generated documentation. |
| 91 | + |
| 92 | +## Contributing |
| 93 | +In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint your code using [Grunt](http://gruntjs.com/). |
| 94 | + |
| 95 | +## Release History |
| 96 | + |
| 97 | +**v1.2.0** |
| 98 | +* new options: theme, name and version |
| 99 | +* now compatible with both 3.x and 4.x version of documentation |
| 100 | +* new theming demo |
| 101 | + |
| 102 | +**v1.1.2** |
| 103 | +* always use latest NPM packages |
| 104 | + |
| 105 | +**v1.1.1** |
| 106 | +* support Grunt 1.0 |
| 107 | + |
| 108 | +**v1.1.0** |
| 109 | +* new feature: `access` option to only include comments with a given access level, out of `private`, `protected`, `public` and `undefined` |
| 110 | +* new feature: `order` option to include user-defined sorting |
| 111 | + |
| 112 | +**v1.0.1** |
| 113 | +* store `md` format at right destination; fixes [issue #3](https://github.com/documentationjs/grunt-documentation/issues/3) |
| 114 | + |
| 115 | +**v1.0.0** |
| 116 | +* Transfered to documentationjs |
0 commit comments