diff --git a/docs/how-it-works.md b/docs/how-it-works.md index 5cc07d80..53a8740c 100644 --- a/docs/how-it-works.md +++ b/docs/how-it-works.md @@ -155,8 +155,21 @@ The base directories for Browser Sync are `.tmp/serve` and `src` with a priority As the `bower_components` folder is not located in any of the base paths, a special routes is added for this folder to be addressed by `/bower_components`. +The default Browser Sync port is `3000`, if you ever need to change it, head over to the [gulp/server.js](https://github.com/Swiip/generator-gulp-angular/blob/master/app/templates/gulp/_server.js#L42) file and add the `port` attribute to the *server* variable. +Example below : +```javascript +browserSync.instance = browserSync.init({ + startPath: '/', + server: server, + browser: browser, + port: 4000 // Add this line to change the default port + }); +``` + Last configuration, the `browser` option is used to open the default browser to the root page. +Head over to [Browser Sync list of options](http://www.browsersync.io/docs/options/) for the full list of available configurations for BrowserSync. + ### Proxy Browser Sync is powered by an express server. The API allows us to inject any Express middleware. Behind comments, an example of use of [http-proxy-middleware](https://github.com/chimurai/http-proxy-middleware) is prepared.