Skip to content

Allow nuxt/nuxt-config-keys-order rule to be used on files chosen by the user #606

@gt-hive-benedict-lee

Description

@gt-hive-benedict-lee

Describe the feature

Currently, nuxt/nuxt-config-keys-order only works on files named exactly as nuxt.config.{ts,js,mts,mjs,tsx,jsx}. As my Nuxt config has grown larger, I am considering separating out the environment configs into their own separate files. In these separate files, I would like to be able to apply the same sort rule that is applied to my main Nuxt config.

However, it is currently impossible to make ESLint apply this rule to those files, as due to these lines processing is immediately stopped on any other file name, and so even if I configure ESLint to apply nuxt/nuxt-config-keys-order to my extracted out environment config file, no errors are given by ESLint.

Additional information

  • Would you be willing to help implement this feature?
  • Could this feature be implemented as a module?

Final checks

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions