Vuejs get Environment Variables

set model File

1
touch .env.test

key=value

MODE=test


use test environment

1
vue-cli-service build --mode development

get the values

1
console.log(process.env.MODE)
#

Comments

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×