Skip to content

Naming convention for settings and rules #403

@javierbrea

Description

@javierbrea

Context

There was confusion in the documentation regarding the naming of the plugin's configuration options, specifically whether to use boundaries/elements or boundaries/element-types.

Accepted Solution

After discussion and community feedback, the following naming convention has been agreed upon:

Settings:

{
  settings: {
    "boundaries/elements": [...]
  }
}

Rules:

{
  rules: {
    "boundaries/dependencies": ["error",...]
  }
}

Rationale

  • boundaries/elements: Defines the elements that rules will use. This name encompasses not just types, but also capturing groups and potential future features like categories and tags.

  • boundaries/dependencies: Controls how elements depend on each other and external dependencies. The term "dependencies" better represents the rule's purpose of managing both internal element relationships and external package dependencies.

Backward compatibility

Old rule names should be valid too, but a warning should be displayed to the user

Reference

See discussion #362 for the full conversation and alternatives considered.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    Status

    Backlog

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions