@codaline-io/parcel-optimizer-replace-envs
v2.4.0
Published
parcel v2 optimizer to replace process.env in files
Downloads
19
Readme
Parcel v2 Optimizer to replace process.env
s
- reads
.env
file whenNODE_ENV
!==production
, defaultprocess.cwd() + '.env'
(full path can be overwritten by settingDOTENV_FILE
- how ironic :D) - replaces occurences of
process.env.X
with the value
How it works
- somehow hacky, because as an optimizer it just uses a dumb regex to replace all
process.env
with its values