mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-23 14:15:13 +00:00
refactor: small improvements (#4194)
This commit is contained in:
parent
a3ba6e96ca
commit
48393b33c7
@ -29,7 +29,8 @@ import {
|
||||
relativeTo,
|
||||
waitFor,
|
||||
determineGlobals,
|
||||
stripWhitespace
|
||||
stripWhitespace,
|
||||
isString
|
||||
} from '@nuxt/common'
|
||||
|
||||
const glob = pify(Glob)
|
||||
@ -372,7 +373,7 @@ export default class Builder {
|
||||
custom: customFileExists
|
||||
}
|
||||
})
|
||||
.filter(i => !!i)
|
||||
.filter(Boolean)
|
||||
|
||||
// -- Custom templates --
|
||||
// Add custom template files
|
||||
@ -524,7 +525,7 @@ export default class Builder {
|
||||
watchServer() {
|
||||
const nuxtRestartWatch = concat(
|
||||
this.options.serverMiddleware
|
||||
.filter(i => typeof i === 'string')
|
||||
.filter(isString)
|
||||
.map(this.nuxt.resolver.resolveAlias),
|
||||
this.options.watch.map(this.nuxt.resolver.resolveAlias),
|
||||
path.join(this.options.rootDir, 'nuxt.config.js')
|
||||
|
@ -99,7 +99,7 @@ export default class PostcssConfig {
|
||||
const instance = plugin(opts)
|
||||
return instance
|
||||
})
|
||||
.filter(e => e)
|
||||
.filter(Boolean)
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user