Skip to content

Commit 95f259c

Browse files
committed
feat(scripts/format): include MDX files by default
1 parent 77c8494 commit 95f259c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
// Jest Snapshot v1, https://goo.gl/fbAQLP
22

3-
exports[`format --config arg can be used for a custom config 1`] = `prettier --write **/*.+(js|json|less|css|ts|tsx|md) --config ./my-config.js`;
3+
exports[`format --config arg can be used for a custom config 1`] = `prettier --write **/*.+(js|json|less|css|ts|tsx|md|mdx) --config ./my-config.js`;
44

5-
exports[`format --ignore-path arg can be used for a custom ignore file 1`] = `prettier --write **/*.+(js|json|less|css|ts|tsx|md) --ignore-path ./.myignore`;
5+
exports[`format --ignore-path arg can be used for a custom ignore file 1`] = `prettier --write **/*.+(js|json|less|css|ts|tsx|md|mdx) --ignore-path ./.myignore`;
66

7-
exports[`format --no-write prevents --write argument from being added 1`] = `prettier **/*.+(js|json|less|css|ts|tsx|md) --no-write`;
7+
exports[`format --no-write prevents --write argument from being added 1`] = `prettier **/*.+(js|json|less|css|ts|tsx|md|mdx) --no-write`;
88

99
exports[`format calls prettier CLI with args 1`] = `prettier --write my-src/**/*.js`;

src/scripts/format.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const relativeArgs = args.map(a => a.replace(`${process.cwd()}/`, ''))
3333

3434
const filesToApply = parsedArgs._.length
3535
? []
36-
: ['**/*.+(js|json|less|css|ts|tsx|md)']
36+
: ['**/*.+(js|json|less|css|ts|tsx|md|mdx)']
3737

3838
const result = spawn.sync(
3939
resolveBin('prettier'),

0 commit comments

Comments
 (0)