PARTIAL WORKAROUND
As a workaround, we are using the below in .prettierrc and hence we cannot utilize 😭 more option like "jsx-double" which is best suited for react configured in tslint
/* .prettierrc */
{
"printWidth": 120, // workaround as 'printWidth' in settings.json / 'max-line-length' in tslint.json not working
"singleQuote": true // partial workaround as usage of '.prettierrc' breaks tslint.json
}
Why do I use ".prettierrc" file
Since I use prettier, tslint as vscode plugins, I prefer maintaining configuration in .vscode/settings.json
What happens if I use ".prettierrc" file
PROBLEM Some of the rules configured by
tslint.json
are not working. One such example is belowPARTIAL WORKAROUND As a workaround, we are using the below in
.prettierrc
and hence we cannot utilize 😭 more option like "jsx-double" which is best suited for react configured in tslintWhy do I use ".prettierrc" file
Since I use prettier, tslint as vscode plugins, I prefer maintaining configuration in
.vscode/settings.json
All the rules working as per the configuration in
tslint.json
and.vscode/settings.json
exceptprintWidth
which is configured in.vscode/settings.json
."max-line-length": [true, 120]
which is configured intslint.json
Hence as a workaround, we are using
.prettierrc
file as suggested in https://github.com/azz/prettier-tslint/issues/15#issuecomment-445638360 but this breaks some of thetslint.json
rules as explained