@tiesen/effect-tanstack-query 0.0.4 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -14,14 +14,17 @@ A lightweight, type-safe bridge between **Effect HTTP API clients** and **TanSta
14
14
  Install using your preferred package manager:
15
15
 
16
16
  ```bash
17
+ # Using npm
18
+ npm install @tiesen/effect-tanstack-query
19
+
20
+ # Using yarn
21
+ yarn add @tiesen/effect-tanstack-query
22
+
17
23
  # Using bun
18
- bun add effect-tanstack-query
24
+ bun add @tiesen/effect-tanstack-query
19
25
 
20
26
  # Using pnpm
21
- pnpm add effect-tanstack-query
22
-
23
- # Using npm
24
- npm install effect-tanstack-query`
27
+ pnpm add @tiesen/effect-tanstack-query
25
28
  ```
26
29
 
27
30
  ## Quick Start
@@ -89,7 +92,7 @@ class ApiClient extends Context.Service<
89
92
 
90
93
  ```ts
91
94
  import { ManagedRuntime } from 'effect'
92
- import { createTanstackQueryOptionsProxy } from 'effect-tanstack-query'
95
+ import { createTanstackQueryOptionsProxy } from '@tiesen/effect-tanstack-query'
93
96
 
94
97
  const runtime = ManagedRuntime.make(ApiClient.live)
95
98
  const api = createTanstackQueryOptionsProxy(ApiClient, runtime)
package/dist/index.d.mts CHANGED
@@ -1,12 +1,12 @@
1
1
  import { Service } from "effect/Context";
2
2
  import { ManagedRuntime } from "effect/ManagedRuntime";
3
- import { DefaultedQueryObserverOptions, MutationOptions } from "@tanstack/query-core";
3
+ import { DefinedInitialDataOptions, MutationOptions } from "@tanstack/react-query";
4
4
  import { Schema } from "effect/Schema";
5
5
  import { Client } from "effect/unstable/httpapi/HttpApiClient";
6
6
  import { HttpApiEndpoint } from "effect/unstable/httpapi/HttpApiEndpoint";
7
7
  //#region src/types.d.ts
8
8
  type TanstackQueryOptionsProxy<T> = T extends Client.Method<HttpApiEndpoint<infer _Key, infer Method, infer _Path, infer Params, infer Query, infer Payload, infer Headers, infer Success, infer Error>, infer _Error, infer _Requires> ? {
9
- queryOptions: Method extends 'GET' ? <TQuery = DefaultedQueryObserverOptions<UnwrapCodec<Success>, UnwrapCodec<Error>>>(input: MakeOptionalInput<([Params] extends [never] ? {} : {
9
+ queryOptions: Method extends 'GET' ? <TQuery = DefinedInitialDataOptions<UnwrapCodec<Success>, UnwrapCodec<Error>>>(input: MakeOptionalInput<([Params] extends [never] ? {} : {
10
10
  params: UnwrapCodec<Params>;
11
11
  }) & ([Query] extends [never] ? {} : {
12
12
  query: UnwrapCodec<Query>;
package/package.json CHANGED
@@ -1,13 +1,29 @@
1
1
  {
2
2
  "name": "@tiesen/effect-tanstack-query",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "private": false,
5
+ "description": " A lightweight, type-safe bridge between Effect HTTP API clients and TanStack Query.",
5
6
  "keywords": [
6
7
  "effect",
7
- "tanstack-intent",
8
- "typesafe"
8
+ "effect-ts",
9
+ "http-api",
10
+ "http-client",
11
+ "proxy",
12
+ "react-query",
13
+ "tanstack",
14
+ "tanstack-query",
15
+ "type-safe",
16
+ "typescript"
9
17
  ],
18
+ "bugs": {
19
+ "url": "https://github.com/tiesen243/effect-tanstack-query/issues"
20
+ },
10
21
  "license": "MIT",
22
+ "author": {
23
+ "name": "Tiesen",
24
+ "email": "tiesen243@tiesen.id.vn",
25
+ "url": "tiesen.id.vn"
26
+ },
11
27
  "repository": {
12
28
  "type": "git",
13
29
  "url": "git+https://github.com/tiesen243/effect-tanstack-query.git"
@@ -44,5 +60,9 @@
44
60
  "peerDependencies": {
45
61
  "@tanstack/react-query": ">=5.100.0",
46
62
  "effect": ">=4.0.0-beta.100 || >=4.0.0"
63
+ },
64
+ "packageManager": "bun@1.3.0",
65
+ "patchedDependencies": {
66
+ "tegami@1.2.7": "patches/tegami@1.2.7.patch"
47
67
  }
48
68
  }