gulp-connect
gulp-connect copied to clipboard
Is there a way to automatically open the browser once the server starts?
Somewhat similar to the open
configuration property provided by gulp-webserver
?
We're using gulp-open for this:
const open = require('gulp-open');
gulp.task('open', function () {
gulp
.src(config.paths.dist.root + 'dev-site/index.html')
.pipe(open({ uri: config.localServer.url, app: 'iexplore' }));
});
gulp.task('run-server', gulp.parallel('connect', 'open'));