Skip to content

Commit

Permalink
Use dev build
Browse files Browse the repository at this point in the history
  • Loading branch information
Soare-Robert-Daniel committed Mar 2, 2022
1 parent 961d4ee commit cab3125
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "1.13.1",
"scripts": {
"start-plugin": "wp-scripts start",
"plugin-build": "wp-scripts build",
"plugin-build": "NODE_ENV=development wp-scripts build",
"linux:make-zip": "npm run plugin-build && zip -r logo_maker_plugin.zip index.php plugin_build && mv logo_maker_plugin.zip development/",
"font:all": "npm run font:config && npm run font:download",
"font:config": "node development/createFontConfigFile.js",
Expand Down
5 changes: 4 additions & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,12 @@ const path = require("path");
const defaultConfig = require( '@wordpress/scripts/config/webpack.config' );
// const GoogleFontsPlugin = require("@beyonk/google-fonts-webpack-plugin")
// const webpackFonts = require("./webpack.fonts.json")
const NODE_ENV = process.env.NODE_ENV || 'development';

module.exports = {
...defaultConfig,
devtool: 'development' === NODE_ENV ? 'eval-source-map' : undefined,
mode: NODE_ENV,
entry: {
"index": "./wordpress/index.tsx",
"logo-maker": "./src/index.tsx"
Expand Down Expand Up @@ -44,4 +47,4 @@ module.exports = {
path: path.resolve(__dirname, "plugin_build"),
clean: true
}
};
};

0 comments on commit cab3125

Please sign in to comment.