In my client-side javascript file if I run the following I get no error:
console.log(process.env.NODE_ENV); // outputs development or production
But if I run the following then I get an error:
console.log(process.env) // Uncaught ReferenceError: process is not defined
Why is this happening? Using Webpack 5 for bundling.