Skip to content
This repository has been archived by the owner on Apr 17, 2023. It is now read-only.

Prettier ignores .prettierrc rules located in root project folder. #931

Closed
bassamanator opened this issue Nov 9, 2020 · 2 comments
Closed

Comments

@bassamanator
Copy link

bassamanator commented Nov 9, 2020

I created a .prettierrc in the root folder of my project.

{
  "trailingComma": "es5",
  "tabWidth": 2,
  "semi": false,
  "singleQuote": true
}

However, prettier continues to add semicolons at the end of my .js files. What have I done wrong here?

(Also, is it possible to get prettier to ignore semicolons, meaning just ignore them (if they're there, leave them, and if they're not there, ignore them)??)

prettier-atom version: 0.60.1
prettier: bundled
prettier version: 2.0.5
prettier-eslint version: 9.0.1
prettier-atom configuration: {
  "formatOnSaveOptions": {
    "enabled": false,
    "respectEslintignore": true,
    "showInStatusBar": false,
    "excludedGlobs": [],
    "whitelistedGlobs": [],
    "isDisabledIfNotInPackageJson": false,
    "isDisabledIfNoConfigFile": false,
    "ignoreNodeModules": true
  },
  "useEslint": false,
  "useStylelint": false,
  "useEditorConfig": true,
  "prettierEslintOptions": {
    "prettierLast": false
  }
}

EDIT: I should also let you know that I don't have prettier installed as a dependency; it's installed in atom and that is all.
EDIT:

Operating System: Manjaro Linux
KDE Plasma Version: 5.20.2
KDE Frameworks Version: 5.75.0
Qt Version: 5.15.1
Kernel Version: 5.8.18-1-MANJARO
OS Type: 64-bit
Processors: 16 × AMD Ryzen 7 2700X Eight-Core Processor
Memory: 15.6 GiB of RAM
Graphics Processor: Radeon RX 580 Series

@robwise
Copy link
Collaborator

robwise commented Jan 22, 2021

@bassamanator Sorry this slipped through the cracks, did you try restarting Atom. We currently have the prettierrc file cached for performance reasons but are not watching for updates. See #270

@robwise
Copy link
Collaborator

robwise commented Jan 22, 2021

Doing some issues clean-up. If this is still an issue, please re-open.

@robwise robwise closed this as completed Jan 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants