2022-11-18 22:05:06 +03:00
|
|
|
# prettier-plugin-jinja-template
|
|
|
|
|
|
|
|
Formatter plugin for jinja2 template files.
|
|
|
|
|
|
|
|
## Install
|
|
|
|
|
|
|
|
```bash
|
2022-12-01 20:01:13 +03:00
|
|
|
npm install --save-dev prettier prettier-plugin-jinja-template
|
2022-11-18 22:05:06 +03:00
|
|
|
```
|
|
|
|
|
|
|
|
## Use
|
|
|
|
|
|
|
|
To use it with basic .html files, you'll have to override the used parser inside your prettier config:
|
|
|
|
|
|
|
|
```json
|
|
|
|
{
|
2022-11-18 23:22:28 +03:00
|
|
|
"overrides": [
|
|
|
|
{
|
|
|
|
"files": ["*.html"],
|
|
|
|
"options": {
|
|
|
|
"parser": "jinja-template"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
2022-11-18 22:05:06 +03:00
|
|
|
}
|
|
|
|
```
|