Get the App
SLTechnology News&Howtos  ›  Development  › 

What is the way to judge the local environment of vue?

Shulou Source: shulou.com Published: 2022-05-31 21:26:13 10月04日 Update

This article mainly introduces the relevant knowledge of "what is the way to judge the local environment of vue". The editor shows you the operation process through an actual case, and the operation method is simple, fast and practical. I hope this article "what is the way to judge the local environment of vue" can help you solve the problem.

Judge the local environment

You only need to install the plug-in cross-env under windows

Npm I cross-env first

Then modify the package.json

Just modify the configuration of dev

You can judge that the environment sets a dynamic proxy.

Determine whether the environment is online or local let development=process.env.NODE_ENV = = 'development'? True: false; 's content on "how to judge the local environment of vue" ends here. Thank you for reading. If you want to know more about the industry, you can follow the industry information channel. The editor will update different knowledge points for you every day.

Tags: Environment way knowledge industry different practical content dynamic practical plug-ins articles methods more cases knowledge points articles information channels processes Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS MySQL Apple Linux Shulou Technology