[Solved] Vue3 process Error: Uncaught ReferenceError: process is not defined

I am used to judging the packaging status according to process in config. This upgrade to vue3 encountered an error
for the solution, configure vite.config.json
add the following configuration.

export default defineConfig({
  // ...
  define: {
    'process.env': process.env
  }
})

Read More: