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

Config - Ability to include subset of another arbitrary JSON file #821

Open
dsherret opened this issue Feb 11, 2024 · 0 comments
Open

Config - Ability to include subset of another arbitrary JSON file #821

dsherret opened this issue Feb 11, 2024 · 0 comments

Comments

@dsherret
Copy link
Member

For example:

// biome.json
{
  "formatter": {
    "enabled": true,
    "indentStyle": "tab",
    "indentWidth": 2,
    "lineWidth": 80,
    "lineEnding": "lf",
    "ignore": []
  }
}

Then something like (not sure about how this should be):

// dprint.json
{
  "biome": {
    // includes the properties in the "formatter" object in biome.js which
    // get flattened into this object
    "$include:biome.json#formatter": {
      "exclude": ["enabled", "ignore"] // excludes these properties
    },
    // anything below overrides what's in the config (while anything above gets overridden)
    "indentStyle": "space"
  }
  // etc...
}

Not sure about the exact syntax or if there's precedence in some other software for how this can be done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant