Closed juliusmarminge closed 7 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
t3-env | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Feb 8, 2024 10:25am |
t3-env-nextjs | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Feb 8, 2024 10:25am |
for some reason, this doesn't work for me.
import createJiti from "jiti"
const jiti = createJiti(new URL(import.meta.url).pathname)
jiti("./src/app/lib/env")
but this does:
import jiti from "jiti"
import { fileURLToPath } from "node:url"
jiti(fileURLToPath(import.meta.url))("./src/app/lib/env")
i got this error when i tried your way:
Error: Cannot find module './src/app/lib/env'
might have something to do with import.meta.url
only working with module
type.
edit: damn, my code also has import.meta.url
hah
Closes #166