Skip to content

Commit

Permalink
Tweaked build settings
Browse files Browse the repository at this point in the history
  • Loading branch information
photonstorm committed Sep 20, 2018
1 parent a39555a commit 25813ce
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 17 deletions.
14 changes: 4 additions & 10 deletions scripts/copy-to-examples-fb.js
@@ -1,14 +1,12 @@
let fs = require('fs-extra');

// let dest = '../phaser3-examples/public/build/dev.js';
// let destMap = '../phaser3-examples/public/build/phaser.js.map';

let source = './build/phaser-facebook-instant-games.js';
let sourceMap = './build/phaser-facebook-instant-games.js.map';
let dest = '../fbtest1/lib/dev.js';
let destMap = '../fbtest1/lib/phaser.js.map';
let destFolder = '../fbtest1/lib/';
let dest = '../fbtest1/lib/phaser-facebook-instant-games.js';
let destMap = '../fbtest1/lib/phaser-facebook-instant-games.js.map';

if (fs.existsSync(dest))
if (fs.existsSync(destFolder))
{
fs.copy(sourceMap, destMap, function (err) {

Expand All @@ -30,7 +28,3 @@ if (fs.existsSync(dest))

});
}
else
{
// console.log('Copy-to-Examples failed: Phaser 3 Examples not present at ../phaser3-examples');
}
7 changes: 3 additions & 4 deletions webpack.dist.config.js
Expand Up @@ -13,9 +13,7 @@ module.exports = {
phaser: './phaser.js',
'phaser.min': './phaser.js',
'phaser-arcade-physics': './phaser-arcade-physics.js',
'phaser-arcade-physics.min': './phaser-arcade-physics.js',
'phaser-facebook-instant-games': './phaser-facebook-instant-games.js',
'phaser-facebook-instant-games.min': './phaser-facebook-instant-games.js'
'phaser-arcade-physics.min': './phaser-arcade-physics.js'
},

output: {
Expand Down Expand Up @@ -51,7 +49,8 @@ module.exports = {
"typeof CANVAS_RENDERER": JSON.stringify(true),
"typeof WEBGL_RENDERER": JSON.stringify(true),
"typeof EXPERIMENTAL": JSON.stringify(false),
"typeof PLUGIN_CAMERA3D": JSON.stringify(false)
"typeof PLUGIN_CAMERA3D": JSON.stringify(false),
"typeof PLUGIN_FBINSTANT": JSON.stringify(false)
}),

new CleanWebpackPlugin([ 'dist' ])
Expand Down
5 changes: 2 additions & 3 deletions webpack.fb.dist.config.js
Expand Up @@ -2,16 +2,15 @@

const webpack = require('webpack');
const UglifyJSPlugin = require('uglifyjs-webpack-plugin');
const CleanWebpackPlugin = require('clean-webpack-plugin');

module.exports = {
mode: 'production',

context: `${__dirname}/src/`,

entry: {
'phaser-facebook-instant-games': './phaser-facebook-instant-games.js',
'phaser-facebook-instant-games.min': './phaser-facebook-instant-games.js'
'phaser-facebook-instant-games': './phaser.js',
'phaser-facebook-instant-games.min': './phaser.js'
},

output: {
Expand Down

0 comments on commit 25813ce

Please sign in to comment.