generator-ng-poly
generator-ng-poly copied to clipboard
Add Support for $locationProvider.html5Mode(true);
For using this feature I needed to add a middleware to browsersync initialization mannually. it would be nice to have it as an option when a module is created
That sounds good to me. If anyone has time for a PR that would be much appreciated.
In case anyone else is looking for how to config browsersync for HTML5 mode, add the middleware by installing this:
npm install connect-history-api-fallback --save-dev
And update gulp/watch.js:
...
gulp.task('browserSync', function() {
$.browserSync({
host: config.host,
open: 'external',
port: config.port,
server: {
verbose: true,
baseDir: config.buildDir,
middleware: $.connectHistoryApiFallback()
}
});
});
...