Add Lit to TanStack Store#908
Conversation
✅ Deploy Preview for tanstack ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
📝 WalkthroughWalkthroughThe PR extends the TanStack store library's framework compatibility by adding ChangesLibrary Framework Configuration
Estimated Code Review Effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/libraries/libraries.ts`:
- Line 495: Remove the unshipped 'lit' entry from the frameworks list to avoid
exposing an adapter that isn't published; specifically update the frameworks
array (the frameworks: [...] declaration) in libraries.ts to remove or comment
out 'lit' and add a TODO/note referencing `@tanstack/lit-store` and upstream PR
`#320` so the gate remains until the package is released.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: b3dc14b1-1639-4612-8ad0-050ff1f24085
📒 Files selected for processing (1)
src/libraries/libraries.ts
| badge: 'alpha', | ||
| repo: 'tanstack/store', | ||
| frameworks: ['react', 'preact', 'solid', 'svelte', 'vue', 'angular'], | ||
| frameworks: ['react', 'preact', 'solid', 'svelte', 'vue', 'angular', 'lit'], |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "1) Check upstream dependency PR status (tanstack/store#320)"
curl -s https://api.github.com/repos/TanStack/store/pulls/320 | jq '{state, merged, mergeable_state, html_url}'
echo
echo "2) Check whether Store Lit docs/framework routes are present in this repo"
rg -n -C2 "store/.*/framework/lit|/store/.*/docs/framework/lit|frameworks:.*lit" --type ts --type md --type mdxRepository: TanStack/tanstack.com
Length of output: 380
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== 1) Check how frameworks array is used in the codebase ==="
rg -n "frameworks" src/libraries/libraries.ts -B5 -A5
echo
echo "=== 2) Search for any Lit-related documentation or content ==="
rg -i "lit" --type ts --type js --type json -g "*/docs/*" -g "*/store/*" -C2 | head -100
echo
echo "=== 3) Check if there's any conditional/feature flag logic for frameworks ==="
rg -n "framework" src/libraries/libraries.ts -B2 -A2
echo
echo "=== 4) Verify the store entry structure and how frameworks drives behavior ==="
rg -n "frameworks.*react|store.*frameworks" -B5 -A10 | head -80Repository: TanStack/tanstack.com
Length of output: 7907
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== 1) Find how frameworks array drives routing/UI ==="
rg -n "frameworks" --type ts --type tsx -A3 -B3 | grep -E "(route|path|link|href|framework)" -A2 -B2 | head -60
echo
echo "=== 2) Check if other libraries with 'lit' (Form, Virtual) have Lit docs ==="
find . -path "*/docs/*" -name "*lit*" -o -path "*/docs/*" -type d -name "*lit*" 2>/dev/null | head -20
echo
echo "=== 3) Search for framework routing patterns ==="
rg "framework\/" --type ts --type tsx --type md -n | head -40
echo
echo "=== 4) Check the actual store directory structure for docs ==="
find . -path "*/store/*" -type f -name "*.md*" -o -path "*/store/docs*" 2>/dev/null | head -30Repository: TanStack/tanstack.com
Length of output: 166
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== 1) Find where frameworks array is used/consumed ==="
rg "frameworks" -A5 -B2 --type ts | grep -v "^--$" | head -100
echo
echo "=== 2) Check if docs/framework routes exist for any library ==="
find . -type d -path "*/docs/*framework*" 2>/dev/null
echo
echo "=== 3) Search for how framework-specific docs are routed ==="
rg "framework" --type ts -C2 | grep -E "(route|path|href|docs)" -C1 | head -60
echo
echo "=== 4) Check actual files in docs directories ==="
find . -path "*/docs*" -type f -name "*.md" 2>/dev/null | grep -i lit | head -10
echo
echo "=== 5) List doc structure for a library with lit in frameworks (e.g., form or virtual) ==="
find . -path "*/form*" -path "*/docs*" -type f 2>/dev/null | head -30Repository: TanStack/tanstack.com
Length of output: 6381
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== 1) Check getFrameworkPackageName to see how 'lit' is handled ==="
rg "getFrameworkPackageName" -A20 -B2 --type ts | head -80
echo
echo "=== 2) Search for actual Lit framework docs/content ==="
rg "lit" --type md -i | grep -E "(framework|doc|guide)" -B2 -A2 | head -60
echo
echo "=== 3) Check if store has package definitions for lit framework ==="
rg "tanstack/store" -A20 -B2 --type ts | grep -E "(package|name|lit)" -C2 | head -50
echo
echo "=== 4) Verify PR `#320` status one more time ==="
curl -s https://api.github.com/repos/TanStack/store/pulls/320 | jq '{state, merged, title, body}' 2>/dev/null | head -30Repository: TanStack/tanstack.com
Length of output: 20046
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== 1) Check if `@tanstack/lit-form` is published on npm ==="
npm view `@tanstack/lit-form` version 2>/dev/null || echo "Not found on npm"
echo
echo "=== 2) Check if `@tanstack/lit-store` is published on npm ==="
npm view `@tanstack/lit-store` version 2>/dev/null || echo "Not found on npm"
echo
echo "=== 3) Check if `@tanstack/lit-query` is published on npm ==="
npm view `@tanstack/lit-query` version 2>/dev/null || echo "Not found on npm"
echo
echo "=== 4) Check if `@tanstack/lit-virtual` is published on npm ==="
npm view `@tanstack/lit-virtual` version 2>/dev/null || echo "Not found on npm"
echo
echo "=== 5) Verify the PR description mentions release coordination ==="
curl -s https://api.github.com/repos/TanStack/tanstack.com/pulls/908 | jq '{title, body, state}' 2>/dev/null | head -50Repository: TanStack/tanstack.com
Length of output: 1020
Block this PR on upstream Lit package release
'lit' is not yet published on npm as @tanstack/lit-store, while other frameworks (Query, Form, Virtual) with Lit support already have published packages. Adding this to frameworks exposes an unshipped adapter in the UI until the upstream PR #320 merges and the package releases. This duplicates the issue across libraries and creates inconsistency in the release timeline. Keep the gate noted in the PR description active until @tanstack/lit-store is published.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@src/libraries/libraries.ts` at line 495, Remove the unshipped 'lit' entry
from the frameworks list to avoid exposing an adapter that isn't published;
specifically update the frameworks array (the frameworks: [...] declaration) in
libraries.ts to remove or comment out 'lit' and add a TODO/note referencing
`@tanstack/lit-store` and upstream PR `#320` so the gate remains until the package
is released.

Summary by CodeRabbit