jan/web/next.config.js
Louis c5925b6a79
feat: explore plugins from the npm repository and install them remotely (#399)
* feat: explore plugins from the npm repository and install them remotely

* refactor: clean out redundant codes

* chore: only show update button on different version
2023-10-19 22:53:55 +07:00

34 lines
734 B
JavaScript

/** @type {import('next').NextConfig} */
const webpack = require("webpack");
const nextConfig = {
output: "export",
assetPrefix: ".",
experimental: {
serverActions: false,
},
images: {
unoptimized: true,
remotePatterns: [
{
protocol: "https",
hostname: "**",
},
],
},
webpack: (config, env) => {
// do some stuff here
config.optimization.minimize = false;
config.optimization.minimizer = [];
config.plugins = [
...config.plugins,
new webpack.DefinePlugin({
PLUGIN_CATALOGS: JSON.stringify("https://cdn.jsdelivr.net/npm/@janhq/plugin-catalog@latest/dist/index.js"),
}),
];
return config;
},
};
module.exports = nextConfig;