@cloudpss/message-stream 0.4.27 → 0.4.28
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/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/index.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -4,5 +4,5 @@ const NIL_UUID = '00000000-0000-0000-0000-000000000000';
|
|
|
4
4
|
export const EMPTY_STREAM_ID = NIL_UUID;
|
|
5
5
|
/** 表示一个空白的流 Token,写入此 Token 的消息会被直接丢弃,不会产生错误 */
|
|
6
6
|
export const EMPTY_STREAM_TOKEN = NIL_UUID;
|
|
7
|
-
export const StreamType = ['object', 'binary'];
|
|
7
|
+
export const StreamType = Object.freeze(['object', 'binary']);
|
|
8
8
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAOA,aAAa;AACb,MAAM,QAAQ,GAAG,sCAA+C,CAAC;AAKjE,+CAA+C;AAC/C,MAAM,CAAC,MAAM,eAAe,GAAG,QAAwC,CAAC;AAMxE,gDAAgD;AAChD,MAAM,CAAC,MAAM,kBAAkB,GAAG,QAA2C,CAAC;AAC9E,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,QAAQ,EAAE,QAAQ,CAAU,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAOA,aAAa;AACb,MAAM,QAAQ,GAAG,sCAA+C,CAAC;AAKjE,+CAA+C;AAC/C,MAAM,CAAC,MAAM,eAAe,GAAG,QAAwC,CAAC;AAMxE,gDAAgD;AAChD,MAAM,CAAC,MAAM,kBAAkB,GAAG,QAA2C,CAAC;AAC9E,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,QAAQ,CAAU,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudpss/message-stream",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.28",
|
|
4
4
|
"author": "CloudPSS",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"clean": "rimraf dist"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"type-fest": "^
|
|
21
|
+
"type-fest": "^4.0.0"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {}
|
|
24
24
|
}
|
package/src/index.ts
CHANGED
|
@@ -20,7 +20,7 @@ export const EMPTY_STREAM_ID = NIL_UUID as Opaque<NIL_UUID, 'StreamId'>;
|
|
|
20
20
|
export type StreamToken = Opaque<UUID, 'StreamToken'>;
|
|
21
21
|
/** 表示一个空白的流 Token,写入此 Token 的消息会被直接丢弃,不会产生错误 */
|
|
22
22
|
export const EMPTY_STREAM_TOKEN = NIL_UUID as Opaque<NIL_UUID, 'StreamToken'>;
|
|
23
|
-
export const StreamType = ['object', 'binary'] as const;
|
|
23
|
+
export const StreamType = Object.freeze(['object', 'binary'] as const);
|
|
24
24
|
/**
|
|
25
25
|
* 流中消息的类型
|
|
26
26
|
* - 'object',在 StreamMessage 中使用 ubjson 存储
|