zoubingwu / msw-auto-mock

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

Update prettier version and improve error handling #44

Closed zoubingwu closed 7 months ago

zoubingwu commented 7 months ago

Fix #41

The prettier version was updated from 2.5.1 to 3.1.0 across package.json and pnpm-lock.yaml. Additionally, in utils.ts, the prettier formatting function was wrapped in a try-catch block to prevent the application from crashing in case of an error, instead reverting back to the original content as a safe fallback. Also, small modifications were made in the test snap files.