Fix mismatching function names
This commit is contained in:
parent
f1a2131540
commit
6694e353ad
4 changed files with 30 additions and 15 deletions
|
|
@ -6,7 +6,7 @@
|
||||||
"author": "András Schmelczer <andras@schmelczer.dev> (https://schmelczer.dev/)",
|
"author": "András Schmelczer <andras@schmelczer.dev> (https://schmelczer.dev/)",
|
||||||
"main": "dist/main.js",
|
"main": "dist/main.js",
|
||||||
"bin": {
|
"bin": {
|
||||||
"declared-server": "dist/main.js"
|
"declared-server": "./dist/main.js"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "npx webpack --mode production",
|
"build": "npx webpack --mode production",
|
||||||
|
|
@ -39,16 +39,18 @@
|
||||||
"eslint-plugin-prettier": "^3.1.4",
|
"eslint-plugin-prettier": "^3.1.4",
|
||||||
"eslint-plugin-unused-imports": "^0.1.3",
|
"eslint-plugin-unused-imports": "^0.1.3",
|
||||||
"file-loader": "^6.1.0",
|
"file-loader": "^6.1.0",
|
||||||
|
"html-webpack-plugin": "^4.5.0",
|
||||||
"nodemon": "^2.0.4",
|
"nodemon": "^2.0.4",
|
||||||
"prettier": "^2.0.5",
|
"prettier": "^2.0.5",
|
||||||
"raw-loader": "^4.0.1",
|
"raw-loader": "^4.0.1",
|
||||||
"resolve-url-loader": "^3.1.1",
|
"resolve-url-loader": "^3.1.1",
|
||||||
"terser-webpack-plugin": "^2.3.5",
|
"terser-webpack-plugin": "^2.3.5",
|
||||||
|
"ts-config-webpack-plugin": "^2.0.0",
|
||||||
"ts-loader": "^8.0.3",
|
"ts-loader": "^8.0.3",
|
||||||
"typescript": "^4.0.3",
|
"typescript": "^4.0.3",
|
||||||
"webpack": "^4.43.0",
|
"webpack": "^4.44.2",
|
||||||
"webpack-cli": "^3.3.12",
|
"webpack-cli": "^3.3.12",
|
||||||
"webpack-dev-server": "^3.10.3",
|
"webpack-dev-server": "^3.11.0",
|
||||||
"webpack-node-externals": "^2.5.2"
|
"webpack-node-externals": "^2.5.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -40,6 +40,7 @@
|
||||||
"sdf-2d": "^0.6.0",
|
"sdf-2d": "^0.6.0",
|
||||||
"socket.io-client": "^2.3.1",
|
"socket.io-client": "^2.3.1",
|
||||||
"source-map-loader": "^1.1.1",
|
"source-map-loader": "^1.1.1",
|
||||||
|
"terser-webpack-plugin": "^4.2.2",
|
||||||
"ts-config-webpack-plugin": "^2.0.0",
|
"ts-config-webpack-plugin": "^2.0.0",
|
||||||
"typescript": "^4.0.3",
|
"typescript": "^4.0.3",
|
||||||
"webpack": "^4.43.0",
|
"webpack": "^4.43.0",
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||||
const ScssConfigWebpackPlugin = require('scss-config-webpack-plugin');
|
const ScssConfigWebpackPlugin = require('scss-config-webpack-plugin');
|
||||||
const TsConfigWebpackPlugin = require('ts-config-webpack-plugin');
|
const TsConfigWebpackPlugin = require('ts-config-webpack-plugin');
|
||||||
const HtmlWebpackInlineSVGPlugin = require('html-webpack-inline-svg-plugin');
|
const HtmlWebpackInlineSVGPlugin = require('html-webpack-inline-svg-plugin');
|
||||||
|
const TerserJSPlugin = require('terser-webpack-plugin');
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
devServer: {
|
devServer: {
|
||||||
|
|
@ -34,6 +35,17 @@ module.exports = {
|
||||||
// see https://github.com/namics/webpack-config-plugins/tree/master/packages/ts-config-webpack-plugin/config
|
// see https://github.com/namics/webpack-config-plugins/tree/master/packages/ts-config-webpack-plugin/config
|
||||||
new TsConfigWebpackPlugin(),
|
new TsConfigWebpackPlugin(),
|
||||||
],
|
],
|
||||||
|
optimization: {
|
||||||
|
minimizer: [
|
||||||
|
new TerserJSPlugin({
|
||||||
|
test: /\.js$/,
|
||||||
|
exclude: /node_modules/,
|
||||||
|
terserOptions: {
|
||||||
|
keep_classnames: true,
|
||||||
|
},
|
||||||
|
}),
|
||||||
|
],
|
||||||
|
},
|
||||||
module: {
|
module: {
|
||||||
rules: [
|
rules: [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,7 @@
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
|
const CleanWebpackPlugin = require('clean-webpack-plugin').CleanWebpackPlugin;
|
||||||
|
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||||
|
const TsConfigWebpackPlugin = require('ts-config-webpack-plugin');
|
||||||
|
|
||||||
const PATHS = {
|
const PATHS = {
|
||||||
entryPoint: path.resolve(__dirname, 'src/main.ts'),
|
entryPoint: path.resolve(__dirname, 'src/main.ts'),
|
||||||
|
|
@ -27,18 +30,15 @@ module.exports = (env, argv) => ({
|
||||||
optimization: {
|
optimization: {
|
||||||
minimize: false,
|
minimize: false,
|
||||||
},
|
},
|
||||||
plugins: [],
|
plugins: [
|
||||||
module: {
|
// Cleans the dist folder before the build starts
|
||||||
rules: [
|
new CleanWebpackPlugin(),
|
||||||
{
|
// Generate a base html file and injects all generated css and js files
|
||||||
test: /\.ts$/,
|
new HtmlWebpackPlugin(),
|
||||||
use: {
|
// Multi threading typescript loader configuration with caching for .ts and .tsx files
|
||||||
loader: 'ts-loader',
|
// see https://github.com/namics/webpack-config-plugins/tree/master/packages/ts-config-webpack-plugin/config
|
||||||
},
|
new TsConfigWebpackPlugin(),
|
||||||
exclude: /node_modules/,
|
],
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
resolve: {
|
resolve: {
|
||||||
extensions: ['.ts'],
|
extensions: ['.ts'],
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue