react web game :
componentDidMount 안에 setInterval 넣기
This commit is contained in:
@@ -1,53 +1,55 @@
|
||||
const path = require('path'); // 경로 조작하는 모듈
|
||||
const RefreshWebpackPlugin = require('@pmmmwh/react-refresh-webpack-plugin');
|
||||
|
||||
const path = require("path"); // 경로 조작하는 모듈
|
||||
const RefreshWebpackPlugin = require("@pmmmwh/react-refresh-webpack-plugin");
|
||||
|
||||
module.exports = {
|
||||
name: 'wordrelay-setting',
|
||||
mode: 'development', // 실 서비스 에서는 production
|
||||
devtool: 'eval',
|
||||
resolve: {
|
||||
extensions: ['.js', '.jsx']
|
||||
},
|
||||
name: "wordrelay-setting",
|
||||
mode: "development", // 실 서비스 에서는 production
|
||||
devtool: "eval",
|
||||
resolve: {
|
||||
extensions: [".js", ".jsx"],
|
||||
},
|
||||
|
||||
entry: {
|
||||
app:['./client'],
|
||||
}, // 입력
|
||||
entry: {
|
||||
app: ["./client"],
|
||||
}, // 입력
|
||||
|
||||
module: {
|
||||
rules: [{
|
||||
test: /\.jsx?$/, // js, jsx 파일에 babel-loader적용
|
||||
loader: 'babel-loader',
|
||||
options: {
|
||||
presets: [
|
||||
['@babel/preset-env', {
|
||||
targets: {
|
||||
browsers: ['> 5% in KR','last 2 chrome versions'],
|
||||
},
|
||||
debug: true,
|
||||
}],
|
||||
'@babel/preset-react'
|
||||
],
|
||||
plugins: [
|
||||
'@babel/plugin-proposal-class-properties',
|
||||
'react-refresh/babel',
|
||||
],
|
||||
},
|
||||
}],
|
||||
}, // 모듈적용
|
||||
|
||||
plugins: [
|
||||
new RefreshWebpackPlugin()
|
||||
],
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: /\.jsx?$/, // js, jsx 파일에 babel-loader적용
|
||||
loader: "babel-loader",
|
||||
options: {
|
||||
presets: [
|
||||
[
|
||||
"@babel/preset-env",
|
||||
{
|
||||
targets: {
|
||||
browsers: ["> 5% in KR", "last 2 chrome versions"],
|
||||
},
|
||||
debug: true,
|
||||
},
|
||||
],
|
||||
"@babel/preset-react",
|
||||
],
|
||||
plugins: [
|
||||
"@babel/plugin-proposal-class-properties",
|
||||
"react-refresh/babel",
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
}, // 모듈적용
|
||||
|
||||
output: {
|
||||
path: path.join(__dirname, 'dist'),
|
||||
filename: 'app.js',
|
||||
publicPath: '/dist/',
|
||||
}, // 출력
|
||||
plugins: [new RefreshWebpackPlugin()],
|
||||
|
||||
devServer: {
|
||||
publicPath: '/dist/',
|
||||
hot: true,
|
||||
},
|
||||
};
|
||||
output: {
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "app.js",
|
||||
publicPath: "/dist/",
|
||||
}, // 출력
|
||||
|
||||
devServer: {
|
||||
publicPath: "/dist/",
|
||||
hot: true,
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user