Skip to content

Commit b279c41

Browse files
nguyenyounatew
authored andcommitted
Fix warning unknown prettier option when running yarn lint. (vercel#34019)
## Documentation / Examples - [x] Make sure the linting passes by running `yarn lint` --- I'm getting this warning when running `yarn lint` on the local: ![Screen Shot 2022-02-05 at 23 45 57](https://user-images.githubusercontent.com/38455472/152651090-be515630-591a-4602-8bd7-eda71174dfda.png) After a quick check, it is caused by the `tailwindConfig` option in the `prettier.config.js` file, added in PR vercel#33614 I guess the reason is because the workspace does not install that plugin. We can safely remove that option in the example, because it's already [the default location](https://github.com/tailwindlabs/prettier-plugin-tailwindcss): > By default the plugin will look for this file in the same directory as your Prettier configuration file. However, if your Tailwind configuration is somewhere else, you can specify this using the tailwindConfig option in your Prettier configuration. ![Screen Shot 2022-02-06 at 00 12 24](https://user-images.githubusercontent.com/38455472/152651623-86655e80-e8d0-45b1-968c-81b7beed48ea.png) The warning is gone after removing that option.
1 parent 1ace577 commit b279c41

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

examples/with-tailwindcss/prettier.config.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,4 @@ module.exports = {
33
singleQuote: true,
44
tabWidth: 2,
55
semi: false,
6-
tailwindConfig: './tailwind.config.js',
76
}

0 commit comments

Comments
 (0)