From 75b141611a47767d27f82b6885165d5dce16e5f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lu=C3=ADs=20Freitas?= Date: Mon, 25 Sep 2023 14:53:49 +0100 Subject: [PATCH 1/2] Update next.config.js --- next.config.js | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/next.config.js b/next.config.js index 2d87705..8d4141e 100644 --- a/next.config.js +++ b/next.config.js @@ -1,7 +1,43 @@ /** @type {import('next').NextConfig} */ + +const execSync = require("child_process").execSync; + const nextConfig = { - images: { domains: ["arweave.net", 'image-cache-service-z3w7d7dnea-ew.a.run.app'] }, + images: { + domains: ["arweave.net", "image-cache-service-z3w7d7dnea-ew.a.run.app"], + }, + + webpack: (config, { isServer, webpack }) => { + if (!isServer) { + config.plugins.push( + new webpack.WatchIgnorePlugin({ + paths: [/.*/], // This tells webpack to not ignore any files. Modify to suit your needs. + }) + ); + + config.plugins.push( + new webpack.HotModuleReplacementPlugin({ + multiStep: true, + }) + ); + + config.plugins.push({ + apply: (compiler) => { + compiler.hooks.watchRun.tapAsync( + "MyCustomScript", + (compilation, callback) => { + // Run your custom script + execSync("node generate-css.js", { stdio: "inherit" }); + + callback(); + } + ); + }, + }); + } + return config; + }, }; module.exports = nextConfig; From d2cc77edeab5b0d8b364757cdc86cbec64b77887 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lu=C3=ADs=20Freitas?= Date: Mon, 25 Sep 2023 14:56:28 +0100 Subject: [PATCH 2/2] Update README.md --- README.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/README.md b/README.md index 94ca339..e3dcc1a 100644 --- a/README.md +++ b/README.md @@ -56,8 +56,6 @@ To run the project locally, use: If you're running your project locally, follow these steps to update your environment variables: 1. Save your changes in the `.env` file. -2. Run `pnpm dev` again to apply the updated environment variables. -3. Reload the page to reflect the changes. ### Deployed on Vercel @@ -68,4 +66,4 @@ If you have deployed your project on Vercel, follow these steps to update your e 3. Update the environment variables in the Vercel dashboard. 4. Trigger a redeployment of your app to apply the changes. -By following these steps, you can ensure that your project uses the updated environment variables. \ No newline at end of file +By following these steps, you can ensure that your project uses the updated environment variables.