This commit is contained in:
Guy Bedford 2020-03-29 09:46:33 -06:00 committed by Joe Haddad
parent 202fcbff7a
commit 7ea2ce8c0e
4 changed files with 14 additions and 2 deletions

View file

@ -62,7 +62,6 @@
"@next/polyfill-nomodule": "9.3.4-canary.0",
"autodll-webpack-plugin": "0.4.2",
"cache-loader": "4.1.0",
"conf": "5.0.0",
"css-loader": "3.3.0",
"cssnano-simple": "1.0.0",
"file-loader": "4.2.0",
@ -167,6 +166,7 @@
"chalk": "2.4.2",
"ci-info": "2.0.0",
"compression": "1.7.4",
"conf": "5.0.0",
"content-type": "1.0.4",
"cookie": "0.4.0",
"devalue": "2.0.1",

View file

@ -334,6 +334,13 @@ export async function ncc_compression(task, opts) {
.target('dist/compiled/compression')
}
// eslint-disable-next-line camelcase
export async function ncc_conf(task, opts) {
await task
.source(opts.src || relative(__dirname, require.resolve('conf')))
.ncc({ packageName: 'conf' })
.target('dist/compiled/conf')
}
// eslint-disable-next-line camelcase
export async function ncc_content_type(task, opts) {
await task
.source(opts.src || relative(__dirname, require.resolve('content-type')))
@ -583,6 +590,7 @@ export async function precompile(task) {
'ncc_chalk',
'ncc_ci_info',
'ncc_compression',
'ncc_conf',
'ncc_content_type',
'ncc_cookie',
'ncc_devalue',

View file

@ -1,5 +1,5 @@
import chalk from 'next/dist/compiled/chalk'
import Conf from 'conf'
import Conf from 'next/dist/compiled/conf'
import { BinaryLike, createHash, randomBytes } from 'crypto'
import isDockerFunction from 'next/dist/compiled/is-docker'
import path from 'path'

View file

@ -67,6 +67,10 @@ declare module 'next/dist/compiled/compression' {
import m from 'compression'
export = m
}
declare module 'next/dist/compiled/conf' {
import m from 'conf'
export = m
}
declare module 'next/dist/compiled/content-type' {
import m from 'content-type'
export = m