Skip to content
This repository was archived by the owner on Apr 8, 2020. It is now read-only.

Commit

Permalink
feat: exclude moment.js
Browse files Browse the repository at this point in the history
  • Loading branch information
t-tajiri committed Mar 22, 2020
1 parent a634001 commit 447965c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Configuration } from '@nuxt/types'
import { Configuration as WebpackConfiguration } from 'webpack'
import i18n from './nuxt-i18n.config'
const purgecss = require('@fullhuman/postcss-purgecss')
const autoprefixer = require('autoprefixer')
Expand Down Expand Up @@ -133,6 +134,10 @@ const config: Configuration = {
whitelistPatterns: [/(col|row)/]
})
]
},
extend(config: WebpackConfiguration, _) {
// default externals option is undefined
config.externals = [{ moment: 'moment' }]
}
// https://ja.nuxtjs.org/api/configuration-build/#hardsource
// hardSource: process.env.NODE_ENV === 'development'
Expand Down

0 comments on commit 447965c

Please sign in to comment.