Deno not found in nextjs15 client component
Building a small scale website with Nextjs 15 and Firebase. I think the issue is that Deno.env.get() works on server components but when its a client component, it doesnt work and it throws this error "Deno is not defined"
4 Replies
the deno namespace doesn't exist in browsers
ah will there be plans for it to be implemented in browsers in the future? and would process.env.XXX be the recommended way to go for deno projects atm or are there better methods
Never used NextJS but if you use
process.env.NEXT_PUBLIC_VARIABLE_NAME
it should work because probably Next bundler will replace them in the build step of the client componentsNo, the deno namespace has things you would not find in a browser environment