当前位置:网站首页>base address: environment variable
base address: environment variable
2022-08-04 03:04:00 【I must win this time】
One. Function
Environment variables: set different variables for different environments
2. Development environment
development
Process:
1. Create a file in the root directory.env.development
2. Set the variables of the corresponding environment in the file
Interface base address; VUE_APP_begins
VUE_APP_URL='Development environment interface base address'
Three. Production environment
production
1. Create a file in the root directory. env.production
2. Set the variables of the corresponding environment in the file
Interface base address; VUE_APP_begins
VUE_APP_URL='production environment interface base address'
Four. Use
process.env.VUE_APP_URL can get the defined value
npm run server development: process.env.VUE_APP_URL===aaa
npm run build production:process.env.VUE_APP_URL===bbb
V. Practical application
In the development environment:
Let's see if we can identify:
Identified.
This allows us to determine a base address in both production and development environments.
边栏推荐
- 说说数据治理中常见的20个问题
- 大佬们,读取mysql300万单表要很长时间,有什么参数可以优惠,或者有什么办法可以快点
- 在更一般意义上验算移位距离和假设
- 6-port full Gigabit Layer 2 network managed industrial Ethernet switch Gigabit 2 optical 4 electrical fiber self-healing ERPS ring network switch
- 架构实战营模块三作业
- pytorch applied to MNIST handwritten font recognition
- 逻辑漏洞----其他类型
- STM8S105K4T6------串口发送和接收
- How to drop all tables under database in MySQL
- Taurus.MVC WebAPI 入门开发教程1:框架下载环境配置与运行(含系列目录)。
猜你喜欢
Countdown to 2 days, the "New Infrastructure of Cultural Digital Strategy and Ecological Construction of Cultural Art Chain" will kick off soon
一文看懂推荐系统:召回04:离散特征处理,one-hot编码和embedding特征嵌入
STM8S105k4t6c--------------点亮LED
自制蓝牙手机app控制stm8/stm32/C51板载LED
三分建设,七分管理!产品、系统、组织三管齐下节能降耗
In the season of going overseas, the localization of Internet tips for going overseas
Flink原理流程图简单记录
Sfdp 超级表单开发平台 V6.0.5 正式发布
【Playwright测试教程】5分钟上手
Zabbix set up email alert + enterprise WeChat alert
随机推荐
一文看懂推荐系统:召回04:离散特征处理,one-hot编码和embedding特征嵌入
[Medical Insurance Science] To maintain the safety of medical insurance funds, we can do this
MRS: Alluxio的使用介绍
2022年最新海南建筑八大员(材料员)模拟考试试题及答案
C语言--环形缓存区
Returns the maximum number of palindromes in a string
[Study Notes Dish Dog Learning C] Dynamic Memory Management
【项目实现】Boost搜索引擎
共n级台阶,每次可以上1级或2级台阶,有多少种上法?
SSLHandshakeException: No appropriate protocol (protocol is disabled or cipher suites are inappropri
[Playwright Test Tutorial] 5 minutes to get started
Sfdp 超级表单开发平台 V6.0.5 正式发布
返回字符串中的最大回文数
Oracle迁移到瀚高之后,空值问题处理
There are n steps in total, and you can go up to 1 or 2 steps each time. How many ways are there?
MCU C language -> usage, and meaning
跨境电商看不到另一面:商家刷单、平台封号、黑灰产牟利
sqoop ETL tool
董明珠直播时冷脸离场,员工频犯低级错误,自家产品没人能弄明白
STM8S项目创建(STVD创建)---使用 COSMIC 创建 C 语言项目