commit | d0182b72a143b0af6675e2644fa9f8c2e03c7b67 | [log] [tgz] |
---|---|---|
author | Seth Ladd <sethladd@google.com> | Fri Aug 28 14:10:56 2015 -0700 |
committer | Seth Ladd <sethladd@google.com> | Fri Aug 28 14:10:56 2015 -0700 |
tree | 0cb344d6f4b51132671b4f7009e10e40012766f6 | |
parent | a446a1313a5b83da1d69f9c1b63b423fa51c2287 [diff] |
bump to 0.6.2 Closes #879 Squashed commit of the following: commit 3888d2ea7c3d56affb44de522dd972d2efc21256 Author: Seth Ladd <sethladd@google.com> Date: Fri Aug 28 14:07:31 2015 -0700 bump to 0.6.2
Use dartdoc to generate HTML documentaton for your Dart package.
Note: As of Dart 1.12-dev.5.10, dartdoc
is shipped with the Dart SDK and replaces docgen
and dartdoc-viewer
.
If you want to contribute to the dartdoc project, see the contributor docs. This page contains information about using the dartdoc tool.
Download the Dart SDK, version 1.12-dev.5.10 or later. If not already added, add the SDK's bin
directory to your PATH.
You can install the latest version of dartdoc with pub
:
$ pub global activate dartdoc
Note: to ensure that this version is run when you type dartdoc on the command line, make sure that ~/.pub-cache/bin is on your PATH, and before the path to the Dart SDK.
Run dartdoc
from the root directory of package. For example:
$ dartdoc Generating documentation for 'server_code_lab' into <path-to-server-code-lab>/server_code_lab/doc/api/ parsing lib/client/piratesapi.dart... parsing lib/common/messages.dart... parsing lib/common/utils.dart... parsing lib/server/piratesapi.dart... Parsed 4 files in 8.1 seconds. generating docs for library pirate.messages from messages.dart... generating docs for library pirate.server from piratesapi.dart... generating docs for library pirate.utils from utils.dart... generating docs for library server_code_lab.piratesApi.client from piratesapi.dart... Documented 4 libraries in 9.6 seconds. Success! Open file:///<path-to-server-code-lab>/server_code_lab/doc/api/index.html
By default, the documentation is generated to the doc/api
directory as static HTML files.
You can view the generated docs directly from the file system, but if you want to use the search function, you must load them with an HTTP server.
An easy way to run an HTTP server locally is to use the simple_http_server
package. For example:
$ pub global activate simple_http_server $ dhttpd --path doc/api
Navigate to localhost:8080
in your browser. The search function should now work.
Command-line options for dartdoc include:
The following options are used only when generating docs for Dart SDK.
Please file reports on the GitHub Issue Tracker.
Please see the dartdoc license.