enjoycoding / vite-plugin-mock-server

A mock server plugin for Vite.
MIT License
58 stars 13 forks source link

mockServer is not a function #17

Closed vinodhum closed 1 year ago

vinodhum commented 1 year ago

Hi I am getting mockServer is not a function

"vite": "^4.0.0",
"vite-plugin-mock-server": "^1.0.4"

import mockServer from 'vite-plugin-mock-server'

and in plugins

 plugins: [react(), mode === "development" && mockServer({
      mockRootDir: './moack',
      mockModules: [mock]
    })],
error when starting dev server:
TypeError: mockServer is not a function
mpilats commented 1 year ago

Have same problem with default config error when starting dev server: TypeError: mockServer is not a function