dewdrop-sdk 0.9.0 → 0.10.0
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/package.json +1 -1
- package/src/index.d.ts +2 -3
- package/src/vite.js +2 -2
package/package.json
CHANGED
package/src/index.d.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
// The types of what `dewdrop-sdk` exports to a game on Dewdrop, which
|
|
2
2
|
// supplies the values where the game runs (src/index.js is only the stub a
|
|
3
|
-
// build without the plugin reaches).
|
|
4
|
-
// module exports, as tests/sync.test.mjs checks.
|
|
3
|
+
// build without the plugin reaches).
|
|
5
4
|
|
|
6
|
-
/** Calls to
|
|
5
|
+
/** Calls to model providers' HTTPS APIs. */
|
|
7
6
|
export interface Llm {
|
|
8
7
|
/** A `fetch` to a provider's HTTPS API; the answer is read whole (`text()`, `json()`, `arrayBuffer()`), not streamed. */
|
|
9
8
|
fetch(input: RequestInfo | URL, init?: RequestInit): Promise<Response>;
|
package/src/vite.js
CHANGED
|
@@ -36,7 +36,7 @@ function shiftMap(json) {
|
|
|
36
36
|
// The imports Dewdrop supplies, left in the output: three and the paths
|
|
37
37
|
// into it, and the SDK by its name. Dewdrop supplies nothing else, a path
|
|
38
38
|
// into the SDK included, so the build takes every other import in.
|
|
39
|
-
export function
|
|
39
|
+
export function isSuppliedModule(id) {
|
|
40
40
|
return id === 'three' || id.startsWith('three/') || id === 'dewdrop-sdk';
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -67,7 +67,7 @@ export default function dew() {
|
|
|
67
67
|
assetsDir: ASSETS_DIR,
|
|
68
68
|
sourcemap: SOURCE_MAPS,
|
|
69
69
|
rollupOptions: {
|
|
70
|
-
external:
|
|
70
|
+
external: isSuppliedModule,
|
|
71
71
|
output: outputOptions(major),
|
|
72
72
|
},
|
|
73
73
|
},
|