Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
plugins.push(...(buildOptions.plugins || []))
plugins.push(new WarningIgnorePlugin(this.warningIgnoreFilter()))
// Build progress indicator
plugins.push(new WebpackBar({
name: this.name,
color: this.colors[this.name],
reporters: [
'basic',
'fancy',
'profile',
'stats'
],
basic: !buildOptions.quiet && env.minimalCLI,
fancy: !buildOptions.quiet && !env.minimalCLI,
profile: !buildOptions.quiet && buildOptions.profile,
stats: !buildOptions.quiet && !this.dev && buildOptions.stats,
reporter: {
change: (_, { shortPath }) => {
if (!this.isServer) {
nuxt.callHook('bundler:change', shortPath)
}
},
done: (buildContext) => {
if (buildContext.hasErrors) {
nuxt.callHook('bundler:error')
}
},
allDone: () => {
nuxt.callHook('bundler:done')
},
export function showBanner (nuxt, showMemoryUsage = true) {
if (env.test) {
return
}
if (env.minimalCLI) {
for (const listener of nuxt.server.listeners) {
consola.info('Listening on: ' + listener.url)
}
return
}
const titleLines = []
const messageLines = []
// Name and version
const { bannerColor } = nuxt.options.cli
titleLines.push(`${chalk[bannerColor].bold('Nuxt.js')} ${nuxt.constructor.version}`)
// Running mode
titleLines.push(`Running in ${nuxt.options.dev ? chalk.bold.blue('development') : chalk.bold.green('production')} mode (${chalk.bold(nuxt.options.mode)})`)
plugins.push(...(buildOptions.plugins || []))
plugins.push(new WarningIgnorePlugin(this.warningIgnoreFilter()))
// Build progress indicator
plugins.push(new WebpackBar({
name: this.name,
color: this.colors[this.name],
reporters: [
'basic',
'fancy',
'profile',
'stats'
],
basic: !buildOptions.quiet && env.minimalCLI,
fancy: !buildOptions.quiet && !env.minimalCLI,
profile: !buildOptions.quiet && buildOptions.profile,
stats: !buildOptions.quiet && !this.dev && buildOptions.stats,
reporter: {
change: (_, { shortPath }) => {
if (!this.isServer) {
nuxt.callHook('bundler:change', shortPath)
}
},
done: (buildContext) => {
if (buildContext.hasErrors) {
nuxt.callHook('bundler:error')
}
},
allDone: () => {
nuxt.callHook('bundler:done')
}
);
emitNetlifyConfig(compilation);
cb();
});
}
});
!this.options.dev &&
webpackConfig.plugins.push(
new WebpackBar({
name: WEBPACK_NETLIFY_COMPILER_NAME,
color: "red",
reporters: ["basic", "fancy", "profile", "stats"],
basic: !this.options.build.quiet && env.minimalCLI,
fancy: !this.options.build.quiet && !env.minimalCLI,
profile: !this.options.build.quiet && this.options.build.profile,
stats:
!this.options.build.quiet &&
!this.options.dev &&
this.options.build.stats,
reporter: {
change: (_, { shortPath }) => {
this.nuxt.callHook("bundler:change", shortPath);
},
done: context => {
if (context.hasErrors) {
this.nuxt.callHook("bundler:error");
}
},
allDone: () => {
);
emitNetlifyConfig(compilation);
cb();
});
}
});
!this.options.dev &&
webpackConfig.plugins.push(
new WebpackBar({
name: WEBPACK_NETLIFY_COMPILER_NAME,
color: "red",
reporters: ["basic", "fancy", "profile", "stats"],
basic: !this.options.build.quiet && env.minimalCLI,
fancy: !this.options.build.quiet && !env.minimalCLI,
profile: !this.options.build.quiet && this.options.build.profile,
stats:
!this.options.build.quiet &&
!this.options.dev &&
this.options.build.stats,
reporter: {
change: (_, { shortPath }) => {
this.nuxt.callHook("bundler:change", shortPath);
},
done: context => {
if (context.hasErrors) {
this.nuxt.callHook("bundler:error");
}
},
allDone: () => {
this.nuxt.callHook("bundler:done");