6 Commits

Author SHA1 Message Date
Jeff Williams
25c37411d9 add @jsdoc/cli and @jsdoc/util modules
`@jsdoc/cli` deals with command-line arguments, and `@jsdoc/util` casts values to appropriate types.
2019-01-26 12:02:55 -08:00
Jeff Williams
4badaef5fd better config loading (#1550)
+ Use `cosmiconfig` instead of rolling our own code (which gives us YAML support)
+ Look for the config in these locations, and in this order:
    + A `jsdoc` property in `package.json`
    + `.jsdocrc` (can be JSON or YAML; comments not allowed for JSON)
    + `.jsdocrc.json` (comments allowed)
    + `.jsdocrc.yaml`
    + `.jsdocrc.yml`
    + `.jsdocrc.js`
    + `jsdoc.config.js`
2019-01-25 19:33:18 -08:00
Jeff Williams
02c1722eb9 use lodash to clone objects 2019-01-21 19:59:33 -08:00
Jeff Williams
f27aba37b7 first pass at template overhaul and template API changes
API changes:
+ No more `jsdoc/template` module. Each JSDoc template uses whatever templating system it wants.
+ No more TaffyDB. Each template finds doclets however it wants. (TODO: Update `jsdoc/util/templateHelper` so none of its methods expect a TaffyDB object.)
+ Templates are now loaded with `require('my-template-name-here')`. The resulting object must include a `publish` method.
+ The `publish` method now takes two parameters: a `data` object with `doclets` and `tutorials` properties, and an `options` object. `data.doclets` is just an array.

Other notable changes:
+ No more `haruki` template.
+ Moved the `default` and `silent` templates to new packages.
+ The `.tmpl` files for the `default` template (now called `@jsdoc/template-original`) no longer use custom delimiters.
2019-01-21 14:13:43 -08:00
Jeff Williams
a29a03b2d9 move jsdoc/util/logger into a new package 2019-01-19 21:49:27 -08:00
Jeff Williams
261c116e03 move jsdoc/src/syntax into a new package 2019-01-19 13:26:16 -08:00