|)(?!.*(|))', 'is');
}
/**
* Build the BrowserSync configuration.
*/
config() {
let userConfig = this.userConfig;
let defaultConfig = {
host: 'localhost',
port: 3000,
proxy: 'app.test',
files: [
'app/**/*.php',
'resources/views/**/*.php',
`${this.context.config.publicPath || 'public'}/**/*.(js|css)`
],
snippetOptions: {
rule: {
match: this.regex(),
fn: function (snippet, match) {
return snippet + match;
}
}
}
};
if (userConfig && userConfig.server) {
delete defaultConfig.proxy;
}
return Object.assign(defaultConfig, userConfig);
}
};