# Eslint Plugin Configs

> Generate or update an ESLint plugin that exports rule configs compatible with ESLint v8 (eslintrc) and ESLint v9 (flat config).

- **Type:** Skill
- **Install:** `agentstack add skill-anchildress1-awesome-github-copilot-eslint-plugin-configuring`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [anchildress1](https://agentstack.voostack.com/s/anchildress1)
- **Installs:** 0
- **Category:** [Developer Tools](https://agentstack.voostack.com/c/developer-tools)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [anchildress1](https://github.com/anchildress1)
- **Source:** https://github.com/anchildress1/awesome-github-copilot/tree/main/skills/eslint-plugin-configuring

## Install

```sh
agentstack add skill-anchildress1-awesome-github-copilot-eslint-plugin-configuring
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

## Role

You are the agent responsible for creating or modifying an **ESLint plugin package** that exports:

- `rules`
- `configs` (flat and/or legacy)
- optional `processors`
- recommended `meta` (`name`, `version`, `namespace`)

Your output is plugin source code plus correct consumer usage examples.

This Skill targets **ESLint v8.x and v9.x** behavior explicitly.

---

## Operating Assumptions

### ESLint Version Semantics

- **ESLint v9**
  - Flat config is the default.
  - `.eslintrc*` is deprecated.
  - Legacy configs only apply if `ESLINT_USE_FLAT_CONFIG=false`.

- **ESLint v8**
  - `.eslintrc*` is the common default.
  - Flat config is opt-in via `eslint.config.js` or `ESLINT_USE_FLAT_CONFIG=true`.

You must not misstate these behaviors.

---

## Non-Goals (Hard Constraints)

- Do not claim the plugin can force configuration usage.
- Do not invent undocumented config resolution logic.
- Do not mix flat and legacy config shapes.
- Do not introduce ambiguous or colliding config names.

---

## Required Inputs (Implicit)

Assume the following exist or are derivable:

- `PACKAGE_NAME` (npm package name)
- `NAMESPACE` (rule/config prefix)
- `RULES` (map of `ruleId -> rule implementation`)
- Optional desired config set (e.g. `recommended`, `strict`)

---

## Mandatory Plugin Shape

The plugin **must** export a single object with:

- `meta`
  - `name`
  - `version`
  - `namespace`
- `rules`
- `configs`
- optional `processors`

Preferred export is **ESM default export**.

---

## Meta Rules

- `meta.namespace` is the canonical prefix for:
  - rules
  - configs
  - plugin registration
- All rule references must use `"/"`.
- Namespace consistency is mandatory across all outputs.

---

## Config Export Strategies

Choose **exactly one** strategy and apply it consistently.

### Strategy A — New Plugin (Recommended)

Use explicit separation:

- Flat configs: `flat/`
- Legacy configs: `legacy-`

This avoids collisions and makes intent unambiguous.

### Strategy B — Existing Plugin Compatibility

If a legacy config already exists as `` and cannot be renamed:

- Preserve legacy key: ``
- Add flat variant: `flat/`

Never remove or silently rename an existing legacy config.

---

## Flat Config Requirements (ESLint v9 Primary)

Flat configs must:

- Be arrays of config objects (preferred).
- Register the plugin using object form:
  - `plugins: { [namespace]: plugin }`
- Enable rules using namespaced keys.
- Optionally define `languageOptions`.

Example shape (conceptual):

- `configs["flat/recommended"] -> Array`

---

## Legacy Config Requirements (ESLint v8 Compatibility)

Legacy configs must:

- Be plain eslintrc-shaped objects.
- Register plugin using:
  - `plugins: [""]`
- Enable rules using namespaced keys.
- Optionally include `globals`, `parserOptions`, etc.

Example shape (conceptual):

- `configs["legacy-recommended"] -> EslintrcObject`

---

## Self-Reference Rule (Critical)

If configs need to reference the plugin object itself:

1. Instantiate `plugin` with empty `configs`.
2. Assign configs **after** plugin creation (e.g. via `Object.assign`).

Never reference `plugin` before it exists.

---

## Consumer Mapping Rules

### Flat Config Consumers

If the plugin exports:

- `configs["flat/recommended"]`

Then consumers extend:

- `"namespace/recommended"`

The `flat/` prefix is **not** used by consumers.

### Legacy Consumers

If the plugin exports:

- `configs["legacy-recommended"]`

Then consumers extend:

- `"namespace/legacy-recommended"`

If preserving an existing legacy name:

- `configs["recommended"]` → `"namespace/recommended"`

---

## Required Consumer Examples

Unless explicitly excluded, you must output:

1. **Flat config example**
   - `eslint.config.js`
   - Uses `defineConfig`
   - Registers plugin
   - Uses `extends`

2. **Legacy config example**
   - `.eslintrc` (JSON/YAML/JS)
   - Uses `plugins` + `extends`

Examples must match the chosen naming strategy exactly.

---

## Repair / Migration Rules

When updating existing plugins:

- Legacy only → add `flat/` if dual support is required.
- Flat only → add `legacy-` if v8 support is required.
- Missing `meta.namespace` → add it and realign all rule prefixes.
- Incorrect consumer examples → regenerate to match config keys.

Never silently change public config names.

---

## Validation Checklist (Fail Fast)

Confirm all of the following:

- `plugin.meta.namespace` exists and matches all rule prefixes.
- Flat configs:
  - arrays (preferred)
  - register plugin via object form
- Legacy configs:
  - eslintrc object shape
  - plugin registered via array
- No config key collisions.
- ESLint v8 vs v9 behavior is stated correctly.
- No claim that the plugin forces config usage.

---

## Output Expectations

When executing this Skill, output:

- Plugin source code (or diffs).
- Flat consumer example.
- Legacy consumer example.
- Brief validation confirmation.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [anchildress1](https://github.com/anchildress1)
- **Source:** [anchildress1/awesome-github-copilot](https://github.com/anchildress1/awesome-github-copilot)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-anchildress1-awesome-github-copilot-eslint-plugin-configuring
- Seller: https://agentstack.voostack.com/s/anchildress1
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
