-
-
Notifications
You must be signed in to change notification settings - Fork 292
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
Add option to explicitly tell xo to use a config file #448
Comments
(Note that this could resolve #250 as well.) |
Would having a minimal config at the root of your repo that extends you global works?
|
@pvdlg Apologies for the delay in my response, I forgot to reply to you. That would work, however I'd say that it would be best to allow people to configure this either in |
I had made the changes for this. Just need to do the final testing, but I'm short on time. https://github.com/mrsauravsahu/xo/tree/feat/config-path-option |
I was able to kind of have a work around for my current project by using a const config = require('../../.xo-config.cjs')
module.exports = {
...config
} Somehow the "parent folder import" for monorepo setups also did not work for me. Not sure if it's related to me using |
In my current project, my xo config file isn't in any of the parent directories of the linted files, but instead in a separate directory. However, I still want to be able to use my custom config, without having to move it to one of the parent directories or publish it to npm.
In my opinion, a decent solution to the issue would be to add a
--config
option to xo, which (when specified) would tell xo to use the configuration at the given path (e.g.xo --config ../.xo-config.json
).I'd appreciate your feedback, and if you agree this should be a part of xo, let me know and I'll be happy to implement this.
The text was updated successfully, but these errors were encountered: