Skip to content

Commit

Permalink
fix(namadillo): removing unused .env injection on Vite config (#1127)
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrorezende authored Sep 19, 2024
1 parent 81f6688 commit c1b2217
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions apps/namadillo/vite.config.mjs
Original file line number Diff line number Diff line change
@@ -1,22 +1,11 @@
/* eslint-disable */
import react from "@vitejs/plugin-react";
import { defineConfig, loadEnv } from "vite";
import { defineConfig } from "vite";
import checker from "vite-plugin-checker";
import { nodePolyfills } from "vite-plugin-node-polyfills";
import tsconfigPaths from "vite-tsconfig-paths";

export default defineConfig(({ mode }) => {
const env = loadEnv(mode, process.cwd(), "");
const filteredEnv = Object.keys(env).reduce((acc, current) => {
if (current.startsWith("NAMADA_INTERFACE_")) {
return {
...acc,
[current]: env[current],
};
}
return acc;
}, {});

export default defineConfig(() => {
return {
plugins: [
react(),
Expand All @@ -30,9 +19,6 @@ export default defineConfig(({ mode }) => {
overlay: { initialIsOpen: false },
}),
],
define: {
"process.env": filteredEnv,
},
optimizeDeps: {
esbuildOptions: {
// Node.js global to browser globalThis
Expand Down

1 comment on commit c1b2217

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.