aws-amplify / aws-amplify/amplify-hosting
$npm_package_version no longer works?
- Dominant language
- Dockerfile
- Stars
- 481
- Forks
- 123
- PR merge metrics
- No merged PRs in 30d
Description
Hi there.
We have a number of Amplify apps and all of them set an environment variable called "REACT_APP_VERSION" to "$npm_package_version"
In all our previous apps, it works as intended in our code:
````
Version {process.env.REACT_APP_VERSION}
````
produces "Version 1.0.1" (or whatever)
However, on a newly deployed app, we're getting
"Version $npm_package_version"
Contributor guide
Research direction
Start by reproducing the reported deployment with REACT_APP_VERSION set to "$npm_package_version" and compare it with the earlier applications described in the report. Trace how Amplify Hosting passes environment variables into the React build; done means determining whether the package version should be expanded or documenting the supported configuration and resulting behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, react
- Domain
- ci-cd, cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100