zoubingwu / msw-auto-mock

A cli tool to generate random mock data from OpenAPI definition for msw.
246 stars 54 forks source link

Incompatible with msw version 2.0 #35

Closed dudnikovoleg closed 7 months ago

dudnikovoleg commented 8 months ago

Hi guys! After the recent update of msw to version 2.0.0 the msw-auto-mock became incompatible.

The first thing I noticed was the import incompatibility import { setupWorker, rest } from "msw"; Also instead of res() now we should use ({ request }) => new Response().

And so on, details can be found in the release - description https://github.com/mswjs/msw/releases/tag/v2.0.0

Do you have any plans to update msw-auto-mock for compatibility in the near future?

Thanks!