Skip to content

Commit

Permalink
Merge a9a5bfb into 841aa91
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmy-guzman committed Apr 30, 2024
2 parents 841aa91 + a9a5bfb commit 4ec5db8
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/long-rats-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"eslint-plugin-astro": patch
---

fix: 🐛 correctly export `meta` for ESM types
4 changes: 2 additions & 2 deletions src/plugin.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { rules as ruleList } from "./utils/rules"
import * as processorsDefines from "./processor"
import type { Rule } from "eslint"
import * as meta from "./meta"
import { name, version } from "./meta"
import { environments } from "./environments"

const rules = ruleList.reduce(
Expand All @@ -17,7 +17,7 @@ const processors = {
"client-side-ts": processorsDefines.clientSideTsProcessor,
}
export const plugin = {
meta,
meta: { name, version },
environments,
rules,
processors,
Expand Down
9 changes: 9 additions & 0 deletions tests/fixtures/integration/config/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"compilerOptions": {
"target": "ESNext",
"module": "ESNext",
"moduleResolution": "Bundler",
"noEmit": true,
"allowJs": true
}
}
4 changes: 4 additions & 0 deletions tests/integration/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,5 +65,9 @@ for (const dirent of fs.readdirSync(TEST_FIXTURES_ROOT, {
}
}
})

it("should NOT fail when running tsc", () => {
cp.execSync(`npx tsc`, { cwd: TEST_CWD })
})
})
}

0 comments on commit 4ec5db8

Please sign in to comment.