This repository has been archived by the owner on Aug 12, 2023. It is now read-only.
-
Hello! I am hoping for some help setting up prettier to work in the following way:
For some reason, I am struggling with this, even though I am sure there must be a simple solution. Thanks in advance for the help. |
Beta Was this translation helpful? Give feedback.
Answered by
fitrh
Feb 8, 2023
Replies: 1 comment 1 reply
-
You can try something like this null_ls.builtins.formatting.prettier.with({
extra_args = function(params)
if vim.fs.dirname(vim.fs.find({ '.prettierrc', '.prettierrc.js' }, { upward = true })[1]) then
return nil
end
return {} -- your extra args
end,
}), |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Callumk7
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can try something like this