clean catalogs

This commit is contained in:
Alexander Popov 2021-07-06 03:31:10 +03:00
parent 0a0ee24a2a
commit 41164ddeaf
Signed by: iiiypuk
GPG Key ID: 398FC73478D97286
9 changed files with 15 additions and 10 deletions

2
app/.gitignore vendored
View File

@ -1,2 +1,2 @@
dist/ engine.js
assets/images/*.jpg assets/images/*.jpg

View File

@ -10,6 +10,6 @@
<canvas id="game" width="400" height="600"></canvas> <canvas id="game" width="400" height="600"></canvas>
</div> </div>
<script type="text/javascript" src="dist/game.js"></script> <script type="text/javascript" src="engine.js"></script>
</body> </body>
</html> </html>

View File

@ -1,7 +1,7 @@
'use strict'; 'use strict';
import config from '../config.json'; // game configuration import config from '../app/config.json'; // game configuration
import gameData from '../gameData.json'; // game data import gameData from '../app/gameData.json'; // game data
import { getMousePos, isInside } from './buttons.js'; import { getMousePos, isInside } from './buttons.js';
import { clearContext, getCenterH, getCenterV } from './draw.js'; import { clearContext, getCenterH, getCenterV } from './draw.js';

View File

@ -2,9 +2,10 @@
"name": "quizEngine", "name": "quizEngine",
"version": "0.0.1", "version": "0.0.1",
"description": "", "description": "",
"main": "index.js", "main": "./js/engine.js",
"scripts": { "scripts": {
"build": "webpack", "start": "webpack serve",
"build": "webpack --mode=production",
"test": "echo \"Error: no test specified\" && exit 1" "test": "echo \"Error: no test specified\" && exit 1"
}, },
"repository": { "repository": {

View File

@ -1,11 +1,15 @@
const path = require('path'); const path = require('path');
module.exports = { module.exports = {
entry: './js/index.js',
context: path.resolve(__dirname, 'app'),
mode: 'development', mode: 'development',
entry: './js/index.js',
output: { output: {
path: path.resolve(__dirname, 'app/dist'), path: path.resolve(__dirname, 'app'),
filename: 'game.js', filename: 'engine.js',
},
devServer: {
contentBase: path.join(__dirname, 'app'),
compress: false,
port: 55555,
}, },
}; };