Skip to content
This repository has been archived by the owner. It is now read-only.
deprecated. Use dartdoc instead.
Dart HTML CSS Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
client
.gitignore
LICENSE
README.md
app.yaml
codereview.settings

README.md

This tool is deprecated in favor of dartdoc.

Please use the new dartdoc tool.


dartdoc-viewer

The front-end Dart documentation viewer.

Here is how our tests are doing: Build Status

Running Dartdoc-Viewer

The viewer uses JSON files generated by the docgen package (currently found in pkg/docgen/ in the Dart repository) to display documentation.

Running Locally

There are two ways to run the viewer locally: in the Dart VM with Dartium or compiled to JavaScript.

Place the JSON files generated from docgen in client/local. Then, depending on whether you're running in Dartium or another browser, follow the directions below:

In Dartium

From the Editor, right click file client/web/index.html and select "Run in Dartium." OR, if you are developing without the editor, start a simple server standing in the top level of this package (such as python -m SimpleHttpServer) and direct Dartium to localhost:$PORT_NUMBER/client/web/index.html.

In Any Browser, Compiled to JavaScript

While standing in the client directory, type pub build. This produces the Javascript and a deployable website at client/build. As with Dartium, you can run in the Editor by right clicking file client/web/index.html and select "Run as JavaScript", OR start a simple server while standing in the top level of this package (such as python -m SimpleHttpServer) and direct any browser to localhost:$PORT_NUMBER/client/web/index.html.

Deployment

Simply copy the entire client/build directory to your deployment server to serve your data.

Special Instructions for Deploying on App Engine, for Official Dart API site

A script streamlining these steps will be forthcoming.

  1. Edit client/lib/shared.dart so that the useHistory boolean is true (You can use this setting with any site on App Engine, provided you resolve the URLs similarly to server/scripts/redirector.py in api.dartlang.org.

  2. Ensure you have a file at lib/config/config.yaml, which contains the key for Google Analytics for your website. Main Dart API site's file can be found here: Link TBD.

  3. Compile the site to JavaScript, by typing pub build while standing in the client directory.

  4. If there is a docs folder inside client/build, delete it (the JSON files are served separately out of Google Cloud Storage, so they should not be uploaded to App Engine).

  5. Check out your App Engine site. In our case: api.dartlang.org

  6. Copy the client/build directory to server/out/web in your api.dartlang.org checkout.

  7. Download the Google App Engine SDK for Python and add it to your PATH.

  8. Run appcfg.py update <folder containing app.yaml>.

You can’t perform that action at this time.