-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[π‘ Feature]: Add plugin.meta to eslint-plugin-wdio for ESLint v9 / oxlint compatibilityΒ #15149
Description
Description
eslint-plugin-wdio currently exports only { configs, rules } at its root β it does not include a meta property on the plugin object.
The ESLint v9 plugin specification designates plugin.meta (containing name and version) as the standard location for plugin identity metadata. While ESLint itself treats meta as optional and falls back to root-level name/version, tools that consume plugins via the ESLint API may depend on plugin.meta being present.
Impact
oxlint JS plugins alpha
oxlint recently shipped a JS plugins alpha (v0.16+) that allows loading standard ESLint plugins. Its internal getPluginName function reads plugin.meta directly:
TypeError: Cannot read properties of undefined (reading 'meta')
at getPluginName (...)
This crash happens on every file when eslint-plugin-wdio is listed in jsPlugins, making the plugin completely unusable in oxlint.
Reproduction
Running oxlint against any file produces:
TypeError: Cannot read properties of undefined (reading 'meta')
Expected behaviour
oxlint (and any other ESLint v9-compatible tooling) can load eslint-plugin-wdio without errors.
Suggested fix
Add a meta object to the plugin export in packages/eslint-plugin-wdio/src/index.ts:
import pkg from '../package.json'
export default {
meta: {
name: 'eslint-plugin-wdio',
version: pkg.version,
},
configs,
rules,
}This is a non-breaking, additive change.
Environment
eslint-plugin-wdio: latestoxlint: v1.55.0 (JS plugins alpha)- ESLint v9 plugin spec: https://eslint.org/docs/latest/extend/plugins#plugin-meta-information