mswjs / msw

Industry standard API mocking for JavaScript.
https://mswjs.io
MIT License
16k stars 522 forks source link

disable prettier as well #2120

Closed scr2em closed 7 months ago

scr2em commented 7 months ago

Scope

Improves an existing behavior, I can add it to .prettierignore but I was wondering maybe we can add it in the file itself like the rest

Compatibility

Feature description

my prettier keeps running on the msw file. is it possible to add disable prettier comment as well ?

/* eslint-disable */
/* tslint:disable */

/**
 * Mock Service Worker (2.1.0).
 * @see https://github.com/mswjs/msw
 * - Please do NOT modify this file.
 * - Please do NOT serve this file on production.
 */
kettanaito commented 7 months ago

Hi, @scr2em.

Configure your Prettier to ignore files in public. You should do that even if you aren't using MSW.

// .prettierignore
/public/mockServiceWorker

// Or, even:
/public