Skip to content

Instantly share code, notes, and snippets.

@PragatiVerma18
Created May 22, 2021 07:58
Show Gist options
  • Select an option

  • Save PragatiVerma18/88e7a4632c98c1bae1c3503a40f5368e to your computer and use it in GitHub Desktop.

Select an option

Save PragatiVerma18/88e7a4632c98c1bae1c3503a40f5368e to your computer and use it in GitHub Desktop.
VueJS Starter Plugin for Adobe Photoshop - webpack.config.js
const { VueLoaderPlugin } = require("vue-loader");
const path = require("path");
const CopyPlugin = require("copy-webpack-plugin");
module.exports = {
entry: "./src/main.js",
output: {
path: path.resolve(__dirname, "dist"),
filename: "main.js",
},
devtool: "cheap-eval-source-map",
externals: {
uxp: "commonjs2 uxp",
photoshop: "commonjs2 photoshop",
os: "commonjs2 os",
},
module: {
rules: [
{
test: /\.vue$/,
loader: "vue-loader",
},
{
test: /\.png$/,
exclude: /node_modules/,
loader: "file-loader",
},
{
test: /\.css$/,
use: ["style-loader", "css-loader"],
},
],
},
plugins: [
new VueLoaderPlugin(),
new CopyPlugin(["plugin"], {
copyUnmodified: true,
}),
],
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment