Giter VIP home page Giter VIP logo

jsdoc-amddcl's Introduction

jsdoc-amddcl

This repositry contains an effort to create a JSDoc template and plugins that work well with AMD and C3MRO-based multiple class inheritance.

Setup

First you need to:

  1. Create a directory, /path/to/jsdoc-amddcl/templates/amddcl/static/scripts/prettify
  2. Download prettify and place prettify.js as well as lang-css.js under /path/to/jsdoc-amddcl/templates/amddcl/static/scripts/prettify
  3. Make sure your project has package.json, so that JSDoc can understand the name of your project

Then you can use the template/plugins by:

$ cd /path/to/jsdoc-amddcl
$ jsdoc -c ./conf.json /path/to/yourproject /path/to/yourproject/README.md /path/to/yourproject/package.json

The conf.json file contains the pointer to our template/plugins, as well as the typical usage pattern using our template/plugins.

You can try a sample project in this repo:

$ cd /path/to/jsdoc-amddcl
$ jsdoc -c ./conf.json ./sampleprojects/sampleproject/ ./sampleprojects/sampleproject/README.md ./sampleprojects/sampleproject/package.json

Importing doclets from other projects

First you export doclets of the dependant projects by JSDoc's -X option:

$ cd /path/to/jsdoc-amddcl
$ mkdir out/dependantproject
$ jsdoc -X -c ./conf.json /path/to/dependantproject /path/to/dependantproject/package.json >! out/dependantproject/doclets.json

All doclets.json files under JSDoc output directory is searched by our plugin to import doclets.

You can try a sample project in this repo:

$ cd /path/to/jsdoc-amddcl
$ mkdir out/sampleframework
$ jsdoc -X -c ./conf.json ./sampleprojects/sampleframework ./sampleprojects/sampleframework/package.json > out/sampleframework/doclets.json

List of changes on top of the original

  • Fix to an issue of duplicate doc of a method. It happens if a method is defined in more than one parent classes, but not in child class.
  • Show modules in AMD format instead of CommonJS format.
  • Makes sure inheritance chain is shown for modules exporting what dcl() returns.
  • Allows you to import doclets from other projects (see above section).

Licensing

This project is distributed by the Dojo Foundation and licensed under the "New" BSD License. All contributions require a Dojo Foundation CLA.

This is a derivative work of JSDoc 3 which is copyright (c) 2011-2014 Michael Mathews [email protected] and the contributors to JSDoc.

JSDoc 3 is free software, licensed under the Apache License, Version 2.0. See the file LICENSE-jsdoc.md in this distribution for more details.

jsdoc-amddcl's People

Contributors

asudoh avatar clmath avatar jdmacd avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.