Skip to content

Conversation

@favna
Copy link
Contributor

@favna favna commented Jul 24, 2024

This is a follow-up from #7766.

While the changes made in #7766 are a good step forward to having a properly typed config, it still doesn't fully work and properly represent the actual code. This PR aims to change that.

With the changes from #7766 pulled in users still run into a typing issue as shown below. This is because of the union of ESLint.ConfigData | Linter.FlatConfig cannot be spread, because they are objects and not arrays. By strictly specifying the types of the different keys this can be resolved.

ishare-1721808850

With this change the config is fully compatible and no ts-expect-error / ts-ignore will be required:

ishare-1721809149

@nx-cloud
Copy link

nx-cloud bot commented Jul 25, 2024

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 85e36fd. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this CI Pipeline Execution


✅ Successfully ran 2 targets

Sent with 💌 from NxCloud.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Jul 25, 2024

commit: 85e36fd

pnpm add https://pkg.pr.new/@tanstack/angular-query-devtools-experimental@7780
pnpm add https://pkg.pr.new/@tanstack/angular-query-experimental@7780
pnpm add https://pkg.pr.new/@tanstack/eslint-plugin-query@7780
pnpm add https://pkg.pr.new/@tanstack/query-async-storage-persister@7780
pnpm add https://pkg.pr.new/@tanstack/query-broadcast-client-experimental@7780
pnpm add https://pkg.pr.new/@tanstack/query-core@7780
pnpm add https://pkg.pr.new/@tanstack/query-devtools@7780
pnpm add https://pkg.pr.new/@tanstack/query-persist-client-core@7780
pnpm add https://pkg.pr.new/@tanstack/query-sync-storage-persister@7780
pnpm add https://pkg.pr.new/@tanstack/react-query@7780
pnpm add https://pkg.pr.new/@tanstack/react-query-devtools@7780
pnpm add https://pkg.pr.new/@tanstack/react-query-next-experimental@7780
pnpm add https://pkg.pr.new/@tanstack/react-query-persist-client@7780
pnpm add https://pkg.pr.new/@tanstack/solid-query@7780
pnpm add https://pkg.pr.new/@tanstack/solid-query-devtools@7780
pnpm add https://pkg.pr.new/@tanstack/solid-query-persist-client@7780
pnpm add https://pkg.pr.new/@tanstack/svelte-query@7780
pnpm add https://pkg.pr.new/@tanstack/svelte-query-devtools@7780
pnpm add https://pkg.pr.new/@tanstack/svelte-query-persist-client@7780
pnpm add https://pkg.pr.new/@tanstack/vue-query@7780
pnpm add https://pkg.pr.new/@tanstack/vue-query-devtools@7780

Open in Stackblitz

More templates

@codecov
Copy link

codecov bot commented Jul 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.00%. Comparing base (5760f70) to head (85e36fd).

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##             main    #7780       +/-   ##
===========================================
+ Coverage   44.58%   84.00%   +39.41%     
===========================================
  Files         185       11      -174     
  Lines        7078      350     -6728     
  Branches     1566      129     -1437     
===========================================
- Hits         3156      294     -2862     
+ Misses       3559       42     -3517     
+ Partials      363       14      -349     
Components Coverage Δ
@tanstack/angular-query-devtools-experimental ∅ <ø> (∅)
@tanstack/angular-query-experimental ∅ <ø> (∅)
@tanstack/eslint-plugin-query 84.00% <ø> (ø)
@tanstack/query-async-storage-persister ∅ <ø> (∅)
@tanstack/query-broadcast-client-experimental ∅ <ø> (∅)
@tanstack/query-codemods ∅ <ø> (∅)
@tanstack/query-core ∅ <ø> (∅)
@tanstack/query-devtools ∅ <ø> (∅)
@tanstack/query-persist-client-core ∅ <ø> (∅)
@tanstack/query-sync-storage-persister ∅ <ø> (∅)
@tanstack/react-query ∅ <ø> (∅)
@tanstack/react-query-devtools ∅ <ø> (∅)
@tanstack/react-query-next-experimental ∅ <ø> (∅)
@tanstack/react-query-persist-client ∅ <ø> (∅)
@tanstack/solid-query ∅ <ø> (∅)
@tanstack/solid-query-devtools ∅ <ø> (∅)
@tanstack/solid-query-persist-client ∅ <ø> (∅)
@tanstack/svelte-query ∅ <ø> (∅)
@tanstack/svelte-query-devtools ∅ <ø> (∅)
@tanstack/svelte-query-persist-client ∅ <ø> (∅)
@tanstack/vue-query ∅ <ø> (∅)
@tanstack/vue-query-devtools ∅ <ø> (∅)

@TkDodo TkDodo merged commit 55486f1 into TanStack:main Jul 25, 2024
@favna favna deleted the fix/eslint-specific-config-keys branch July 25, 2024 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants