Skip to content

feat: support for solid-js #92

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/solid-db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# @tanstack/react-db

## 0.0.27

- Add support for solid-js
3 changes: 3 additions & 0 deletions packages/solid-db/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# @tanstack/solid-db

Solidjs hooks for TanStack DB. See [TanStack/db](https://github.com/TanStack/db) for more details.
65 changes: 65 additions & 0 deletions packages/solid-db/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"name": "@tanstack/solid-db",
"description": "Solid integration for @tanstack/db",
"version": "0.0.27",
"author": "Kyle Mathews",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/TanStack/db.git",
"directory": "packages/solid-db"
},
"homepage": "https://tanstack.com/db",
"keywords": [
"optimistic",
"solid",
"typescript"
],
"packageManager": "[email protected]",
"dependencies": {
"@solid-primitives/map": "^0.7.2",
"@tanstack/db": "workspace:*",
"use-sync-external-store": "^1.2.0"
},
"devDependencies": {
"@electric-sql/client": "1.0.0",
"@solidjs/testing-library": "^0.8.10",
"@types/use-sync-external-store": "^0.0.6",
"@vitest/coverage-istanbul": "^3.0.9",
"jsdom": "^26.0.0",
"solid-js": "^1.9.7",
"vite-plugin-solid": "^2.11.7",
"vitest": "^3.0.9"
},
"exports": {
".": {
"import": {
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
"require": {
"types": "./dist/cjs/index.d.cts",
"default": "./dist/cjs/index.cjs"
}
},
"./package.json": "./package.json"
},
"files": [
"dist",
"src"
],
"main": "dist/cjs/index.cjs",
"module": "dist/esm/index.js",
"peerDependencies": {
"solid-js": ">=1.9.0"
},
"scripts": {
"build": "vite build",
"dev": "vite build --watch",
"test": "vitest --run",
"lint": "eslint . --fix"
},
"sideEffects": false,
"type": "module",
"types": "dist/esm/index.d.ts"
}
9 changes: 9 additions & 0 deletions packages/solid-db/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
// Re-export all public APIs
export * from "./useLiveQuery"

// Re-export everything from @tanstack/db
export * from "@tanstack/db"

// Re-export some stuff explicitly to ensure the type & value is exported
export type { Collection } from "@tanstack/db"
export { createTransaction } from "@tanstack/db"
Loading
Loading