Current Behavior
These changes broke the parsing of process.env: #30826
The values are loaded during build time, which can be checked by console.log inside webpack.config, but whatever solution you try to pass them forward, they are lost inside the built app.
If you console.log the process.env global variable, you always get an empty object, while before this version this always yielded the variables prefixed by NX_PUBLIC_
Expected Behavior
You can use process.env to see and access your environment variables
GitHub Repo
No response
Steps to Reproduce
- create a .env file and put some variables inside
- update to v22.2.2
- verify that inside the app process.env no longer works
Nx Report
Node : 24.13.0
OS : win32-x64
Native Target : x86_64-windows
pnpm : 10.28.2
nx : 22.2.7
@nx/js : 22.2.7
@nx/jest : 22.2.7
@nx/eslint : 22.2.7
@nx/workspace : 22.2.7
@nx/cypress : 22.2.7
@nx/devkit : 22.2.7
@nx/eslint-plugin : 22.2.7
@nx/module-federation : 22.2.7
@nx/react : 22.2.7
@nx/rollup : 22.2.7
@nx/vite : 22.2.7
@nx/vitest : 22.2.7
@nx/web : 22.2.7
@nx/webpack : 22.2.7
typescript : 5.9.3
---------------------------------------
Cache Usage: 0.00 B / 47.15 GB
Failure Logs
Package Manager Version
No response
Operating System
Additional Information
No response
Current Behavior
These changes broke the parsing of process.env: #30826
The values are loaded during build time, which can be checked by console.log inside webpack.config, but whatever solution you try to pass them forward, they are lost inside the built app.
If you console.log the process.env global variable, you always get an empty object, while before this version this always yielded the variables prefixed by NX_PUBLIC_
Expected Behavior
You can use process.env to see and access your environment variables
GitHub Repo
No response
Steps to Reproduce
Nx Report
Failure Logs
Package Manager Version
No response
Operating System
Additional Information
No response