Skip to content

Fix lint tooling and isolate type-aware config#1108

Open
richardjoo wants to merge 1 commit into
emdash-cms:mainfrom
richardjoo:split/tooling-lint-fixes
Open

Fix lint tooling and isolate type-aware config#1108
richardjoo wants to merge 1 commit into
emdash-cms:mainfrom
richardjoo:split/tooling-lint-fixes

Conversation

@richardjoo

Copy link
Copy Markdown
Contributor

What does this PR do?

Restores the workspace lint/type-aware tooling path by isolating oxlint's type-aware config and avoiding a failing tsgo path in @emdash-cms/registry-client.

Closes #

  • Adds a dedicated tsconfig.oxlint.json for type-aware oxlint runs.
  • Updates root lint scripts to use that dedicated tsconfig.
  • Switches @emdash-cms/registry-client typecheck to tsc --noEmit.
  • Simplifies one redundant type annotation in packages/plugin-cli/src/commands/info.ts.
  • Removes the crashing @e18e/eslint-plugin JS-plugin integration from oxlint config.

Type of change

  • Bug fix
  • Feature (requires maintainer-approved Discussion)
  • Refactor (no behavior change)
  • Translation
  • Documentation
  • Performance improvement
  • Tests
  • Chore (dependencies, CI, tooling)

Checklist

  • I have read CONTRIBUTING.md
  • pnpm typecheck passes
  • pnpm lint passes
  • pnpm test passes (or targeted tests for my change)
  • pnpm format has been run
  • I have added/updated tests for my changes (if applicable)
  • User-visible strings in the admin UI are wrapped for translation (if applicable). Do not include messages.po changes except in translation PRs — a workflow extracts catalogs on merge to main.
  • I have added a changeset (if this PR changes a published package)
  • New features link to an approved Discussion: https://github.com/emdash-cms/emdash/discussions/...

AI-generated code disclosure

  • This PR includes AI-generated code — model/tool: GPT-5.4 / OpenCode

Screenshots / test output

  • pnpm lint passes with 0 errors on this branch.
  • pnpm format:check passes.
  • pnpm --filter @emdash-cms/registry-client typecheck passes.
  • Note: full pnpm typecheck currently hits an unrelated @emdash-cms/auth-atproto import-resolution failure present on top of current upstream and not touched by this PR.

Copilot AI review requested due to automatic review settings May 19, 2026 19:15
@changeset-bot

changeset-bot Bot commented May 19, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: e16b051

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR restores/steadies the workspace lint + type-aware tooling by isolating Oxlint’s type-aware TypeScript configuration, removing a crashing JS-plugin integration, and adjusting @emdash-cms/registry-client’s typecheck flow to avoid the failing tsgo path.

Changes:

  • Add a dedicated tsconfig.oxlint.json and update root lint scripts to use it for type-aware Oxlint runs.
  • Remove @e18e/eslint-plugin integration + rules from .oxlintrc.json.
  • Switch @emdash-cms/registry-client’s typecheck to tsc --noEmit and tweak its TS lib settings; simplify a redundant type annotation in plugin CLI.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tsconfig.oxlint.json Introduces a dedicated TS config for type-aware Oxlint runs with targeted excludes.
package.json Points lint/lint:json/lint:fix at the dedicated oxlint tsconfig.
.oxlintrc.json Removes the crashing jsPlugins integration and associated e18e/* rule configuration.
packages/registry-client/package.json Changes typecheck to use tsc --noEmit instead of tsgo.
packages/registry-client/tsconfig.json Drops esnext.typedarrays from lib.
packages/plugin-cli/src/commands/info.ts Removes a redundant type annotation (keeps inferred type).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .oxlintrc.json
Comment on lines 2 to 4
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": ["typescript", "import", "unicorn", "promise"],
"jsPlugins": ["@e18e/eslint-plugin"],
"categories": {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After removing the jsPlugins integration from .oxlintrc.json, @e18e/eslint-plugin was no longer used anywhere in the repo.

I removed it from package.json and updated the lockfile so the branch no longer installs an unused dependency.

@github-actions

Copy link
Copy Markdown
Contributor

Overlapping PRs

This PR modifies files that are also changed by other open PRs:

This may cause merge conflicts or duplicated work. A maintainer will coordinate.

@ascorbic

Copy link
Copy Markdown
Collaborator

Can you explain what this was fixing? I wasn't aware of it failing.

@richardjoo

Copy link
Copy Markdown
Contributor Author

Can you explain what this was fixing? I wasn't aware of it failing.

This wasn't me fixing an already-red main/CI failure so much as cleaning up a tooling path I tripped over locally while working on lint setup.

The concrete break I could point to was the oxlint config still referencing @e18e/eslint-plugin via jsPlugins after removing that dependency. In that state, type-aware oxlint crashed immediately with:
Failed to parse oxlint configuration file.
Failed to load JS plugin: @e18e/eslint-plugin
Cannot find module '@e18e/eslint-plugin'

So the .oxlintrc + dependency cleanup part was the real fix.

The tsconfig.oxlint.json part was me making the type-aware oxlint path explicit and narrower instead of pointing it at the generic root TS config, and the registry-client tsc swap was me trying to avoid a tsgo path I hit locally while iterating.

If that reads broader than warranted, I'm happy to trim the PR down to just the minimal oxlint/config consistency fix.

@github-actions github-actions Bot added the review/needs-rereview Author pushed changes since the last review label May 30, 2026
@ascorbic

ascorbic commented Jun 1, 2026

Copy link
Copy Markdown
Collaborator

Hi. Can you explain the problem this is fixing?

@pkg-pr-new

pkg-pr-new Bot commented Jun 12, 2026

Copy link
Copy Markdown

Open in StackBlitz

@emdash-cms/admin

npm i https://pkg.pr.new/@emdash-cms/admin@1108

@emdash-cms/auth

npm i https://pkg.pr.new/@emdash-cms/auth@1108

@emdash-cms/auth-atproto

npm i https://pkg.pr.new/@emdash-cms/auth-atproto@1108

@emdash-cms/blocks

npm i https://pkg.pr.new/@emdash-cms/blocks@1108

@emdash-cms/cloudflare

npm i https://pkg.pr.new/@emdash-cms/cloudflare@1108

@emdash-cms/contentful-to-portable-text

npm i https://pkg.pr.new/@emdash-cms/contentful-to-portable-text@1108

emdash

npm i https://pkg.pr.new/emdash@1108

create-emdash

npm i https://pkg.pr.new/create-emdash@1108

@emdash-cms/gutenberg-to-portable-text

npm i https://pkg.pr.new/@emdash-cms/gutenberg-to-portable-text@1108

@emdash-cms/plugin-cli

npm i https://pkg.pr.new/@emdash-cms/plugin-cli@1108

@emdash-cms/plugin-types

npm i https://pkg.pr.new/@emdash-cms/plugin-types@1108

@emdash-cms/registry-client

npm i https://pkg.pr.new/@emdash-cms/registry-client@1108

@emdash-cms/registry-lexicons

npm i https://pkg.pr.new/@emdash-cms/registry-lexicons@1108

@emdash-cms/sandbox-workerd

npm i https://pkg.pr.new/@emdash-cms/sandbox-workerd@1108

@emdash-cms/x402

npm i https://pkg.pr.new/@emdash-cms/x402@1108

@emdash-cms/plugin-ai-moderation

npm i https://pkg.pr.new/@emdash-cms/plugin-ai-moderation@1108

@emdash-cms/plugin-atproto

npm i https://pkg.pr.new/@emdash-cms/plugin-atproto@1108

@emdash-cms/plugin-audit-log

npm i https://pkg.pr.new/@emdash-cms/plugin-audit-log@1108

@emdash-cms/plugin-color

npm i https://pkg.pr.new/@emdash-cms/plugin-color@1108

@emdash-cms/plugin-embeds

npm i https://pkg.pr.new/@emdash-cms/plugin-embeds@1108

@emdash-cms/plugin-field-kit

npm i https://pkg.pr.new/@emdash-cms/plugin-field-kit@1108

@emdash-cms/plugin-forms

npm i https://pkg.pr.new/@emdash-cms/plugin-forms@1108

@emdash-cms/plugin-webhook-notifier

npm i https://pkg.pr.new/@emdash-cms/plugin-webhook-notifier@1108

commit: e16b051

Keep the lint-tooling fix focused on the stale oxlint JS-plugin path and a dedicated type-aware tsconfig, without pulling in the unrelated registry-client and plugin-cli changes from the older branch.
@richardjoo richardjoo force-pushed the split/tooling-lint-fixes branch from cc7a4e1 to e16b051 Compare June 13, 2026 18:30
@richardjoo

Copy link
Copy Markdown
Contributor Author

Hi. Can you explain the problem this is fixing?

I trimmed this PR down to the minimal fix.

The actual issue here was that type-aware oxlint was still configured to load @e18e/eslint-plugin via jsPlugins, and that path had become stale. The result was that the type-aware lint path failed before it could do useful work.

The branch now only does four things:

  • removes the stale jsPlugins + e18e/* rule config from .oxlintrc.json
  • removes the now-unused @e18e/eslint-plugin dependency
  • adds a dedicated tsconfig.oxlint.json
  • points the root lint scripts at that dedicated tsconfig

I dropped the unrelated registry-client and plugin-cli changes, so this PR is only about the lint-config/tooling fix itself.

I apologize for the late reply. I hope this clarifies your question.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants