#Environment variable on the front end.
1 messages · Page 1 of 1 (latest)
still not working, i got the error that says process is undefined (so is import)
bun v1.2.15 btw
@unkempt vessel it works similar to find and replace (but with the ast). is the environment variable statically analyzable? like process.env.FOO and not process.env[myVariable]
Yeah, they are statically analyzable, like when i try to run this code:
const HOST = process.env.BUN_PUBLIC_HOST_URL;
const PORT = import.meta.env.BUN_PUBLIC_PORT;
I got process is not defined and hmr.importMeta.env is undefined
I filed an issue on Github