N
N
nezzard2016-10-21 13:41:24
npm
nezzard, 2016-10-21 13:41:24

How to make gulp react to all files?

Good afternoon, how to rewrite this line correctly so that it reacts to all links?

gulp.task('browser-sync', function() { 
  browserSync({ 
    proxy: "domain.loc",
    notify: false 
  });
});

If I work with the main localhost:3000, then the reload works fine, but if I go to localhost:3000/contacts/, then when the file that is responsible for this page changes, only the main one is reloaded, but this one is not.
What needs to be written or added?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Savely Dzvonkevich, 2016-10-21
@nezzard

I also use BrowserSync. I have it implemented like this:

var config = {
    server: {
        baseDir: './build/'
    },
    tunnel: false,
    host: 'localhost',
    port: 8080,
    logPrefix: "dzvonkevich"
};

gulp.task('webserver', function () {
    browserSync(config);
});

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question