Shared Prettier config for Astro projects.
- Install package as a dev dependency
npm install --save-dev @nharox/astro-prettier-config
- Update
package.json
{
// ...
"prettier": "@nharox/astro-prettier-config"
}
- Add the following script in your
package.json
{
// ...
"scripts": {
// ...
"format": "prettier --write \"src/**/*.{astro,ts}\""
}
}