@instantdb/solidjs 0.0.1

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.
Files changed (48) hide show
  1. package/.tshy/build.json +8 -0
  2. package/.tshy/commonjs.json +16 -0
  3. package/.tshy/esm.json +15 -0
  4. package/.turbo/turbo-build.log +69 -0
  5. package/dist/commonjs/InstantSolidDatabase.d.ts +156 -0
  6. package/dist/commonjs/InstantSolidDatabase.d.ts.map +1 -0
  7. package/dist/commonjs/InstantSolidDatabase.js +265 -0
  8. package/dist/commonjs/InstantSolidDatabase.js.map +1 -0
  9. package/dist/commonjs/InstantSolidRoom.d.ts +97 -0
  10. package/dist/commonjs/InstantSolidRoom.d.ts.map +1 -0
  11. package/dist/commonjs/InstantSolidRoom.js +200 -0
  12. package/dist/commonjs/InstantSolidRoom.js.map +1 -0
  13. package/dist/commonjs/index.d.ts +6 -0
  14. package/dist/commonjs/index.d.ts.map +1 -0
  15. package/dist/commonjs/index.js +24 -0
  16. package/dist/commonjs/index.js.map +1 -0
  17. package/dist/commonjs/package.json +3 -0
  18. package/dist/commonjs/version.d.ts +3 -0
  19. package/dist/commonjs/version.d.ts.map +1 -0
  20. package/dist/commonjs/version.js +5 -0
  21. package/dist/commonjs/version.js.map +1 -0
  22. package/dist/esm/InstantSolidDatabase.d.ts +156 -0
  23. package/dist/esm/InstantSolidDatabase.d.ts.map +1 -0
  24. package/dist/esm/InstantSolidDatabase.js +257 -0
  25. package/dist/esm/InstantSolidDatabase.js.map +1 -0
  26. package/dist/esm/InstantSolidRoom.d.ts +97 -0
  27. package/dist/esm/InstantSolidRoom.d.ts.map +1 -0
  28. package/dist/esm/InstantSolidRoom.js +191 -0
  29. package/dist/esm/InstantSolidRoom.js.map +1 -0
  30. package/dist/esm/index.d.ts +6 -0
  31. package/dist/esm/index.d.ts.map +1 -0
  32. package/dist/esm/index.js +18 -0
  33. package/dist/esm/index.js.map +1 -0
  34. package/dist/esm/package.json +3 -0
  35. package/dist/esm/version.d.ts +3 -0
  36. package/dist/esm/version.d.ts.map +1 -0
  37. package/dist/esm/version.js +3 -0
  38. package/dist/esm/version.js.map +1 -0
  39. package/dist/standalone/index.js +7010 -0
  40. package/dist/standalone/index.umd.cjs +7 -0
  41. package/package.json +63 -0
  42. package/src/InstantSolidDatabase.ts +363 -0
  43. package/src/InstantSolidRoom.ts +319 -0
  44. package/src/index.ts +191 -0
  45. package/src/version.ts +2 -0
  46. package/tsconfig.dev.json +14 -0
  47. package/tsconfig.json +45 -0
  48. package/vite.config.ts +20 -0
package/src/index.ts ADDED
@@ -0,0 +1,191 @@
1
+ import {
2
+ id,
3
+ tx,
4
+ lookup,
5
+ i,
6
+
7
+ // error
8
+ InstantAPIError,
9
+
10
+ // sync table enums
11
+ SyncTableCallbackEventType,
12
+
13
+ // types
14
+ type QueryResponse,
15
+ type InstantQuery,
16
+ type InstantQueryResult,
17
+ type InstantSchema,
18
+ type InstantObject,
19
+ type InstantEntity,
20
+ type InstantSchemaDatabase,
21
+ type InstantUnknownSchemaDef,
22
+ type IInstantDatabase,
23
+ type User,
24
+ type AuthState,
25
+ type Query,
26
+ type Config,
27
+ type InstaQLParams,
28
+ type ConnectionStatus,
29
+ type ValidQuery,
30
+
31
+ // presence types
32
+ type PresencePeer,
33
+
34
+ // schema types
35
+ type AttrsDefs,
36
+ type CardinalityKind,
37
+ type DataAttrDef,
38
+ type EntitiesDef,
39
+ type EntitiesWithLinks,
40
+ type EntityDef,
41
+ type InstantGraph,
42
+ type InstantConfig,
43
+ type LinkAttrDef,
44
+ type LinkDef,
45
+ type LinksDef,
46
+ type ResolveAttrs,
47
+ type ValueTypes,
48
+ type InstaQLEntity,
49
+ type InstaQLFields,
50
+ type InstaQLResult,
51
+ type InstaQLEntitySubquery,
52
+ type RoomsOf,
53
+ type RoomsDef,
54
+ type PresenceOf,
55
+ type TopicsOf,
56
+ type TopicOf,
57
+ type RoomHandle,
58
+ type TransactionChunk,
59
+ type InstantUnknownSchema,
60
+ type InstantSchemaDef,
61
+ type BackwardsCompatibleSchema,
62
+ type InstantRules,
63
+ type UpdateParams,
64
+ type LinkParams,
65
+ type CreateParams,
66
+ type ExchangeCodeForTokenParams,
67
+ type SendMagicCodeParams,
68
+ type SendMagicCodeResponse,
69
+ type SignInWithIdTokenParams,
70
+ type VerifyMagicCodeParams,
71
+ type VerifyResponse,
72
+
73
+ // storage types
74
+ type FileOpts,
75
+ type UploadFileResponse,
76
+ type DeleteFileResponse,
77
+
78
+ // sync table types
79
+ type SyncTableCallback,
80
+ type SyncTableCallbackEvent,
81
+ type SyncTableInitialSyncBatch,
82
+ type SyncTableInitialSyncComplete,
83
+ type SyncTableSyncTransaction,
84
+ type SyncTableLoadFromStorage,
85
+ type SyncTableSetupError,
86
+ StoreInterface,
87
+ createInstantRouteHandler,
88
+ type StoreInterfaceStoreName,
89
+ } from '@instantdb/core';
90
+
91
+ import { InstantSolidDatabase } from './InstantSolidDatabase.js';
92
+ import { init, init_experimental } from './InstantSolidDatabase.js';
93
+ import { InstantSolidRoom } from './InstantSolidRoom.js';
94
+
95
+ export {
96
+ id,
97
+ tx,
98
+ lookup,
99
+ init,
100
+ init_experimental,
101
+ InstantSolidDatabase,
102
+ InstantSolidRoom,
103
+ i,
104
+
105
+ // error
106
+ InstantAPIError,
107
+
108
+ // sync table enums
109
+ SyncTableCallbackEventType,
110
+
111
+ // types
112
+ type Config,
113
+ type InstantConfig,
114
+ type InstantUnknownSchemaDef,
115
+ type Query,
116
+ type QueryResponse,
117
+ type InstantObject,
118
+ type User,
119
+ type AuthState,
120
+ type ConnectionStatus,
121
+ type InstantQuery,
122
+ type InstantQueryResult,
123
+ type InstantSchema,
124
+ type InstantEntity,
125
+ type InstantSchemaDatabase,
126
+ type IInstantDatabase,
127
+ type InstaQLParams,
128
+ type ValidQuery,
129
+ type InstaQLFields,
130
+
131
+ // presence types
132
+ type PresencePeer,
133
+
134
+ // schema types
135
+ type AttrsDefs,
136
+ type CardinalityKind,
137
+ type DataAttrDef,
138
+ type EntitiesDef,
139
+ type EntitiesWithLinks,
140
+ type EntityDef,
141
+ type InstantGraph,
142
+ type LinkAttrDef,
143
+ type LinkDef,
144
+ type LinksDef,
145
+ type ResolveAttrs,
146
+ type ValueTypes,
147
+ type InstaQLEntity,
148
+ type InstaQLResult,
149
+ type InstaQLEntitySubquery,
150
+ type RoomsOf,
151
+ type RoomsDef,
152
+ type TransactionChunk,
153
+ type PresenceOf,
154
+ type TopicsOf,
155
+ type TopicOf,
156
+ type RoomHandle,
157
+ type InstantUnknownSchema,
158
+ type InstantSchemaDef,
159
+ type BackwardsCompatibleSchema,
160
+ type InstantRules,
161
+ type UpdateParams,
162
+ type LinkParams,
163
+ type CreateParams,
164
+ type ExchangeCodeForTokenParams,
165
+ type SendMagicCodeParams,
166
+ type SendMagicCodeResponse,
167
+ type SignInWithIdTokenParams,
168
+ type VerifyMagicCodeParams,
169
+ type VerifyResponse,
170
+
171
+ // storage types
172
+ type FileOpts,
173
+ type UploadFileResponse,
174
+ type DeleteFileResponse,
175
+
176
+ // custom store
177
+ StoreInterface,
178
+ type StoreInterfaceStoreName,
179
+
180
+ // sync table types
181
+ type SyncTableCallback,
182
+ type SyncTableCallbackEvent,
183
+ type SyncTableInitialSyncBatch,
184
+ type SyncTableInitialSyncComplete,
185
+ type SyncTableSyncTransaction,
186
+ type SyncTableLoadFromStorage,
187
+ type SyncTableSetupError,
188
+
189
+ // Server helper
190
+ createInstantRouteHandler,
191
+ };
package/src/version.ts ADDED
@@ -0,0 +1,2 @@
1
+ import { version } from '@instantdb/version';
2
+ export default version;
@@ -0,0 +1,14 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "module": "es2022",
5
+ "target": "es2022",
6
+ "moduleResolution": "bundler",
7
+
8
+ "outDir": "./dist/esm",
9
+
10
+ "declaration": true,
11
+ "declarationDir": "./dist/esm",
12
+ "incremental": true
13
+ }
14
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,45 @@
1
+ {
2
+ "extends": "../../tsconfig.base.json",
3
+ // Visit https://aka.ms/tsconfig to read more about this file
4
+ "compilerOptions": {
5
+ // File Layout
6
+ "rootDir": "./src",
7
+ "outDir": "./dist",
8
+
9
+ // Environment Settings
10
+ // See also https://aka.ms/tsconfig/module
11
+ "module": "nodenext",
12
+ "target": "esnext",
13
+ "types": [],
14
+ // For nodejs:
15
+ // "lib": ["esnext"],
16
+ // "types": ["node"],
17
+ // and npm install -D @types/node
18
+
19
+ // Other Outputs
20
+ "sourceMap": true,
21
+ "declaration": true,
22
+ "declarationMap": true,
23
+
24
+ // Stricter Typechecking Options
25
+ "noUncheckedIndexedAccess": true,
26
+ "exactOptionalPropertyTypes": true,
27
+
28
+ // Style Options
29
+ // "noImplicitReturns": true,
30
+ // "noImplicitOverride": true,
31
+ // "noUnusedLocals": true,
32
+ // "noUnusedParameters": true,
33
+ // "noFallthroughCasesInSwitch": true,
34
+ // "noPropertyAccessFromIndexSignature": true,
35
+
36
+ // Recommended Options
37
+ "strict": true,
38
+ "jsx": "preserve",
39
+ "isolatedModules": true,
40
+ "noUncheckedSideEffectImports": true,
41
+ "moduleDetection": "force",
42
+ "skipLibCheck": true
43
+ },
44
+ "include": ["src"]
45
+ }
package/vite.config.ts ADDED
@@ -0,0 +1,20 @@
1
+ import { defineConfig } from 'vite';
2
+ import { resolve } from 'path';
3
+
4
+ export default defineConfig({
5
+ clearScreen: false,
6
+ build: {
7
+ outDir: 'dist/standalone',
8
+ lib: {
9
+ formats: ['umd', 'es'],
10
+ // this is the file that exports our components
11
+ entry: resolve(__dirname, 'src', 'index.ts'),
12
+ name: 'instantSolidjs',
13
+ fileName: 'index',
14
+ },
15
+ rollupOptions: {},
16
+ },
17
+ define: {
18
+ 'process.env': {},
19
+ },
20
+ });