mirror of
https://github.com/pmndrs/zustand.git
synced 2025-12-08 19:45:52 +00:00
build: target es2018 (#2361)
This commit is contained in:
parent
9cb1c67827
commit
453b3a65f8
@ -25,10 +25,11 @@ function getBabelOptions(targets) {
|
||||
}
|
||||
}
|
||||
|
||||
function getEsbuild(target, env = 'development') {
|
||||
function getEsbuild(env = 'development') {
|
||||
return esbuild({
|
||||
minify: env === 'production',
|
||||
target,
|
||||
target: 'es2018',
|
||||
supported: { 'import-meta': true },
|
||||
tsconfig: path.resolve('./tsconfig.json'),
|
||||
})
|
||||
}
|
||||
@ -73,7 +74,7 @@ function createESMConfig(input, output) {
|
||||
delimiters: ['\\b', '\\b(?!(\\.|/))'],
|
||||
preventAssignment: true,
|
||||
}),
|
||||
getEsbuild('node12'),
|
||||
getEsbuild(),
|
||||
],
|
||||
}
|
||||
}
|
||||
@ -162,7 +163,7 @@ function createSystemConfig(input, output, env) {
|
||||
delimiters: ['\\b', '\\b(?!(\\.|/))'],
|
||||
preventAssignment: true,
|
||||
}),
|
||||
getEsbuild('node12', env),
|
||||
getEsbuild(env),
|
||||
],
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user