Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use plugins #118

Closed
kddnewton opened this issue Dec 10, 2020 · 1 comment · Fixed by #128
Closed

Use plugins #118

kddnewton opened this issue Dec 10, 2020 · 1 comment · Fixed by #128
Labels

Comments

@kddnewton
Copy link
Member

Hey there - I'm attempting to use pretty-quick with the Ruby plugin, but it's not quite working. I'm not sure if it's a bug at all or if I'm using the configuration incorrectly.

The issue is that prettier.resolveConfig.sync ignores Ruby files not matter what I try to do. I'm not 100% sure on the prettier APIs here, but if in isSupportedExtension.js I change:

import { getFileInfo } from 'prettier';

export default (resolveConfig) => (file) =>
  Boolean(getFileInfo.sync(file, { resolveConfig }).inferredParser);

to:

import * as prettier from 'prettier';

export default (resolveConfig) => (file) =>
  Boolean(getFileInfo.sync(file, {
    resolveConfig,
    ...prettier.resolveConfig.sync(file, { editorconfig: true }, { filepath: file })
  }).inferredParser);

it fixes itself.

ustramooner added a commit to ustramooner/pretty-quick that referenced this issue Apr 14, 2021
@azz azz closed this as completed in #128 Jun 17, 2021
@azz
Copy link
Member

azz commented Jun 17, 2021

🎉 This issue has been resolved in version 3.1.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@azz azz added the released label Jun 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants