@deepseek-ai/dsh-client-modules 0.1.6-alpha.1 → 0.1.6-alpha.2
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.i18n.yaml +2 -2
- package/README.md +16 -5
- package/README.zh.md +16 -5
- package/lib/client.js +407 -26
- package/lib/index.js +139 -72
- package/lib/types/client/entries.d.ts +76 -0
- package/lib/types/client/entry-lifecycle.d.ts +14 -0
- package/lib/types/client/index.d.ts +2 -0
- package/lib/types/client/manifest.d.ts +26 -14
- package/lib/types/client/system.d.ts +13 -8
- package/lib/types/index.d.ts +12 -7
- package/package.json +5 -4
package/lib/types/index.d.ts
CHANGED
|
@@ -109,11 +109,12 @@ export declare class ClientModuleRegistry extends Service {
|
|
|
109
109
|
/**
|
|
110
110
|
* Serve an advertised revisioned bundle or source map without a Web server.
|
|
111
111
|
* Unknown URLs return 404, unsupported methods return 405, and `HEAD`
|
|
112
|
-
* returns the same immutable headers without a body.
|
|
112
|
+
* returns the same immutable headers without materializing a body. Each body
|
|
113
|
+
* is built once on its first `GET`; script construction never reads maps.
|
|
113
114
|
* @param request - shell-carrier request for a `/plugins` resource.
|
|
114
115
|
* @returns the exact response also exposed by the optional Web route.
|
|
115
116
|
*/
|
|
116
|
-
fetchBundle(request: Request): Response
|
|
117
|
+
fetchBundle(request: Request): Promise<Response>;
|
|
117
118
|
/**
|
|
118
119
|
* Filesystem baseline captured before an entry's current bytes were read.
|
|
119
120
|
* HMR compares it with the live files when installing a watch, so a write
|
|
@@ -124,8 +125,8 @@ export declare class ClientModuleRegistry extends Service {
|
|
|
124
125
|
*/
|
|
125
126
|
artifactBaseline(id: string): ClientArtifactBaseline | undefined;
|
|
126
127
|
/**
|
|
127
|
-
*
|
|
128
|
-
* point through which
|
|
128
|
+
* Publish one completed bundle generation (the HMR watch's registration
|
|
129
|
+
* hook — the only entry point through which build changes reach the graph).
|
|
129
130
|
* @param id - entry id (package name).
|
|
130
131
|
* @returns the new rev, or undefined for an unknown id.
|
|
131
132
|
*/
|
|
@@ -165,20 +166,24 @@ export declare class ClientModuleRegistry extends Service {
|
|
|
165
166
|
/** Allocate an opaque initial row revision without inspecting artifact bytes. */
|
|
166
167
|
private allocateInitialRevision;
|
|
167
168
|
/**
|
|
168
|
-
* Read the activation-time bundle
|
|
169
|
+
* Read the activation-time bundle snapshot.
|
|
169
170
|
* @param pkgName - package that declares the client bundle.
|
|
170
171
|
* @param clientPath - absolute path of the built client artifact.
|
|
171
172
|
* @returns the immutable bytes plus the pre-read filesystem baseline.
|
|
172
173
|
* @throws {MissingClientBundleError} when the read fails with `ENOENT`; other filesystem errors are rethrown unchanged.
|
|
173
174
|
*/
|
|
174
175
|
private initialBundleSnapshot;
|
|
175
|
-
/** Treat a missing, torn, or malformed development map as an identity
|
|
176
|
-
private
|
|
176
|
+
/** Treat a missing, torn, or malformed development map as an identity section. */
|
|
177
|
+
private readonly readSourceMap;
|
|
177
178
|
/** Reconcile one entry name against the live Loader sources. @returns whether the table changed. */
|
|
178
179
|
private processOne;
|
|
179
180
|
private resolveSource;
|
|
180
181
|
private reconcilePackage;
|
|
181
182
|
private flush;
|
|
183
|
+
/** Match an exact current-revision package-local chunk URL without reading its file. */
|
|
184
|
+
private chunkRequest;
|
|
185
|
+
/** Build a package-local chunk response only when its URL is requested. */
|
|
186
|
+
private chunkResponse;
|
|
182
187
|
private bundleResource;
|
|
183
188
|
private readonly serveBundle;
|
|
184
189
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-client-modules",
|
|
3
3
|
"description": "Client module system, dual-face: node half composes the __DSH_BOOT__ entry graph (incremental dsh.client scan, bundle route, index tap, webPlugins service); browser half is the lazy-CJS module table the vendored cordis Loader consumes as its internal seam",
|
|
4
|
-
"version": "0.1.6-alpha.
|
|
4
|
+
"version": "0.1.6-alpha.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -38,11 +38,12 @@
|
|
|
38
38
|
},
|
|
39
39
|
"license": "MIT",
|
|
40
40
|
"devDependencies": {
|
|
41
|
+
"@deepseek-ai/dsh-host-webserver": "^0.1.6-alpha.2",
|
|
42
|
+
"@deepseek-ai/dsh-invariants": "^0.1.6-alpha.2",
|
|
41
43
|
"@deepseek-ai/cordis-plugin-loader": "^1.0.3",
|
|
42
|
-
"@deepseek-ai/dsh-host-webserver": "^0.1.6-alpha.1",
|
|
43
|
-
"@deepseek-ai/dsh-invariants": "^0.1.6-alpha.1",
|
|
44
44
|
"@deepseek-ai/cordis": "^4.0.2",
|
|
45
|
-
"@deepseek-ai/dsh-package-manifest": "^0.1.6-alpha.
|
|
45
|
+
"@deepseek-ai/dsh-package-manifest": "^0.1.6-alpha.2",
|
|
46
|
+
"@deepseek-ai/dsh-client-store": "^0.1.6-alpha.2"
|
|
46
47
|
},
|
|
47
48
|
"files": [
|
|
48
49
|
"lib/index.js",
|