docs(README): add instructions for testing docs

This commit is contained in:
Andy Joslin
2014-03-10 09:32:13 -06:00
parent c79a7e52d6
commit c07846a49d
4 changed files with 15 additions and 4 deletions

View File

@@ -83,7 +83,7 @@ For most cases, you'll need AngularJS as well. This is bundled in `js/angular/`
* `npm install && npm install -g gulp protractor` to setup
* `gulp` or `gulp build` to build
* `gulp docs` to generate docs (they are generated in tmp/ionic-site; clone ionic-site there if you wish to test them).
* `gulp docs` to generate docs (read Documentation below for how to test docs locally).
* `gulp build --release` to build with minification & strip debugs
* `gulp watch` to watch and rebuild on change
* `gulp karma` to test one-time
@@ -91,6 +91,17 @@ For most cases, you'll need AngularJS as well. This is bundled in `js/angular/`
* `gulp protractor` to test e2e tests locally
* `gulp cloudtest` to run e2e tests in the cloud
### Documentation
* To test documentation, follow these steps:
1. Clone ionic-site to `./tmp/ionic-site` - this is where the `gulp docs` task builds to. `./tmp` is the folder that travis uses to do all of its tasks.
- `mkdir tmp && git clone git@github.com:driftyco/ionic-site tmp/ionic-site`
2. Make jekyll rebuild whenever you change the site.
- `cd tmp/ionic-site && jekyll serve -w`
3. Build the docs
- `gulp docs`
4. Open localhost:4000 and see your changes! Re-run `gulp docs` again whenever you change something, and jekyll will update the site.
### Commit Conventions
* Uses http://github.com/ajoslin/conventional-changelog conventions

View File

@@ -10,7 +10,7 @@ module.exports = function(config) {
config = basePackage(config);
config.set('logging.level', 'debug');
config.set('logging.level', 'info');
config.prepend('rendering.templateFolders', [
path.resolve(__dirname, 'templates')

View File

@@ -37,7 +37,7 @@ gulp.task('default', ['build']);
gulp.task('build', ['bundle', 'sass']);
gulp.task('docs', function() {
dgeni('docs/docs.config.js').generateDocs();
return dgeni('docs/docs.config.js').generateDocs();
});
var IS_WATCH = false;

View File

@@ -195,7 +195,7 @@ function($parse, $timeout, $ionicScrollDelegate, $controller, $ionicBind) {
* @description
* The ionInfiniteScroll directive, when placed inside of {@link ionic.directive:ionContent ionContent}, allows you to call a function whenever the user gets to the bottom of the page or near the bottom of the page.
*
* The expression you pass in for `on-scroll` is called when the user scrolls down until he is `distance` away from the bottom of the screen.
* The expression you pass in for `on-infinite` is called when the user scrolls greater than `distance` away from the bottom of the content.
*
* @param {expression} on-infinite What to call when the scroller reaches the bottom.
* @param {string=} distance The distance from the bottom that the scroll must reach to trigger the on-infinite expression. Default 1%.