webpack lodash 간소화
This commit is contained in:
@@ -7,8 +7,12 @@
|
|||||||
"browsers": [
|
"browsers": [
|
||||||
"last 2 versions"
|
"last 2 versions"
|
||||||
]
|
]
|
||||||
}
|
},
|
||||||
|
"modules":false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
],
|
||||||
|
"plugins": [
|
||||||
|
"lodash"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1,4 +1,4 @@
|
|||||||
import _, {random} from "lodash";
|
import {random, range} from "lodash"
|
||||||
|
|
||||||
declare global {
|
declare global {
|
||||||
interface Window { formStart: any; }
|
interface Window { formStart: any; }
|
||||||
@@ -11,7 +11,7 @@ function formStart() {
|
|||||||
|
|
||||||
const a = 10;
|
const a = 10;
|
||||||
const b:number[] = [];
|
const b:number[] = [];
|
||||||
for(const v of _.range(10)){
|
for(const v of range(10)){
|
||||||
b.push(random()*v);
|
b.push(random()*v);
|
||||||
}
|
}
|
||||||
console.log(a + 10);
|
console.log(a + 10);
|
||||||
|
|||||||
@@ -23,6 +23,7 @@
|
|||||||
"@babel/preset-env": "^7.15.0",
|
"@babel/preset-env": "^7.15.0",
|
||||||
"@babel/preset-typescript": "^7.15.0",
|
"@babel/preset-typescript": "^7.15.0",
|
||||||
"babel-loader": "^8.2.2",
|
"babel-loader": "^8.2.2",
|
||||||
|
"babel-plugin-lodash": "^3.3.4",
|
||||||
"pre-commit": "^1.2.2",
|
"pre-commit": "^1.2.2",
|
||||||
"typescript": "^4.3.5",
|
"typescript": "^4.3.5",
|
||||||
"webpack": "^5.49.0",
|
"webpack": "^5.49.0",
|
||||||
|
|||||||
+1
-1
@@ -5,7 +5,7 @@
|
|||||||
/* Basic Options */
|
/* Basic Options */
|
||||||
// "incremental": true, /* Enable incremental compilation */
|
// "incremental": true, /* Enable incremental compilation */
|
||||||
"target": "esnext", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', 'ES2021', or 'ESNEXT'. */
|
"target": "esnext", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', 'ES2021', or 'ESNEXT'. */
|
||||||
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */
|
"module": "ESNext", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */
|
||||||
// "lib": [], /* Specify library files to be included in the compilation. */
|
// "lib": [], /* Specify library files to be included in the compilation. */
|
||||||
// "allowJs": true, /* Allow javascript files to be compiled. */
|
// "allowJs": true, /* Allow javascript files to be compiled. */
|
||||||
// "checkJs": true, /* Report errors in .js files. */
|
// "checkJs": true, /* Report errors in .js files. */
|
||||||
|
|||||||
+2
-2
@@ -4,7 +4,7 @@ module.exports = [
|
|||||||
{
|
{
|
||||||
name: 'ingame',
|
name: 'ingame',
|
||||||
resolve: {
|
resolve: {
|
||||||
extensions: [".ts", ".tsx"]
|
extensions: [".js", ".ts", ".tsx"]
|
||||||
},
|
},
|
||||||
entry: {
|
entry: {
|
||||||
inheritPoint: './hwe/ts/inheritPoint.ts',
|
inheritPoint: './hwe/ts/inheritPoint.ts',
|
||||||
@@ -34,7 +34,7 @@ module.exports = [
|
|||||||
{
|
{
|
||||||
name: 'gateway',
|
name: 'gateway',
|
||||||
resolve: {
|
resolve: {
|
||||||
extensions: [".ts", ".tsx"]
|
extensions: [".js", ".ts", ".tsx"]
|
||||||
},
|
},
|
||||||
entry: {
|
entry: {
|
||||||
//test: './ts/test.ts',
|
//test: './ts/test.ts',
|
||||||
|
|||||||
Reference in New Issue
Block a user