open

The open configuration is similar to Rspack's devServer open configuration, used to specify whether to open the browser after project startup.

  • 类型boolean
  • 默认值: false

When we want the browser to automatically open and access the project after startup, we can set it to true.

💡TIP: Note that the automatically opened browser will be the system default browser.

示例

emp-config.js
export default defineConfig(store => {
  ...
  return {
    ...
    server: {
      open: true,
      ...
    },
    ...
  }
})

This configuration example means the browser will automatically open and access the project after startup.

ON THIS PAGE