You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Clean up doc tags and move towards JSDoc
- name modules consistently following commonjs pathing
- fix missing types for some functions
- add missing blocks for some functions
- begin thinking about how to structure doc blocks to generate comprehensive
overview of code surface
* Add a @SInCE 1.1.0 tag to setHeaders methods
* Wrap @example descriptions in <caption> tags
* Standardize on @returns in JSDoc blocks
* Remove YUIDoc and its references
* Switch inline documentation to JSDoc
Fixes#316
Copy file name to clipboardexpand all lines: CONTRIBUTING.md
+10-4
Original file line number
Diff line number
Diff line change
@@ -111,11 +111,13 @@ We prefer `camelCase` variable and function names, and `UpperCamelCase` construc
111
111
112
112
## Documentation
113
113
114
-
The README getting started guide & YUIDoc block comment should be kept up-to-date with feature development: If you aren't familiar with adding doc blocks, we'll help you work through it in the comments of your PR.
114
+
The README getting started guide & [JSDoc](http://usejsdoc.org/) block comment should be kept up-to-date with featrbenvure development: If you aren't familiar with adding JSDoc comments, we'll help you work through it in the comments of your PR.
115
115
116
-
The API docs will be updated whenever a new NPM module version is published. No files within `docs/` should be committed in any branch other than gh-pages.
116
+
The API docs will be updated whenever a new NPM module version is published. No generated files within `documentation/` should be committed in any branch other than gh-pages.
117
117
118
-
To generate the docs yourself, run `npm run docs` (aliased to `grunt yuidoc`).
118
+
To generate the docs yourself, run `npm run docs`. This task will parse the README into a series of individual markdown files, then run JSDoc to generate the API reference. These files will be consumed by GitHub Pages to render the final public [wp-api.org/node-wpapi](http://wp-api.org/node-wpapi) website.
119
+
120
+
Preview the generated documentation site locally with `npm run jekyll`. To install Jekyll you will need Ruby (v2.3.x is required due to a dependency issue in 2.4), then run `gem install bundler` and `bundle install` from the `documentation/` directory.
119
121
120
122
## Branch Naming & Pull Requests
121
123
@@ -127,7 +129,11 @@ Internally, we try to use the following branch naming scheme to keep things orga
127
129
***build/feature-name**: Features relating to the build process, Gruntfile, linting or testing process, NPM package, *etcetera*
128
130
***docs/feature-name**: Documentation, README, contributing guide, fleshing out inline doc blocks; anything in the repository that's authored to be human-readable
129
131
130
-
It is not essential to maintain this naming structure in your own branches, though it is preferred; the important thing is that pull requests *not* be submitted from your master branch.
132
+
It is not essential to maintain this naming structure in your own branches; the important thing is that pull requests *not* be submitted from your master branch.
133
+
134
+
## Release "Props"
135
+
136
+
Code is only a small part of the effort that goes into maintaining an open source project. We recognize both code _and_ non-code contributions with release "props," celebrating those who devote time and energy to the `wpapi` package. If you open an issue that highlights a bug, or contribute documentation and user guides, you will receive recognition for your support in the release notes where the associated code or documentation changes appear. Please participate constructively in [issue](https://github.com/wp-api/node-wpapi/issues) discussions, and thank you for your support!
Copy file name to clipboardexpand all lines: README.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -928,7 +928,7 @@ var wp = new WPAPI({
928
928
929
929
## API Documentation
930
930
931
-
In addition to the above getting-started guide, we have automatically-generated [API documentation](http://wp-api.github.io/node-wpapi).
931
+
In addition to the above getting-started guide, we have automatically-generated [API documentation](http://wp-api.github.io/node-wpapi/api-reference/).
Welcome to the API Reference for the `wpapi` NPM package.
4
+
5
+
Running `require( 'wpapi' )` returns the `WPAPI` constructor, which you can read about by clicking its name in the class list in the menu. Each request handler factory on `WPAPI` (such as `.posts()`, `.pages()`, _etc._) returns a `WPRequest` object, conditionally augmented with one or more mixins depending on the capabilities of the associated endpoints.
6
+
7
+
For user guides & tutorials, visit [wp-api.org/node-wpapi/](http://wp-api.org/node-wpapi).
0 commit comments