@squide/msw 3.1.1 → 3.2.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.
- package/CHANGELOG.md +20 -0
- package/dist/{chunk-AMKPYN4M.js → chunk-CL6F3JZI.js} +1 -1
- package/dist/{chunk-W5GMS2JV.js → chunk-NDT73ZLW.js} +6 -5
- package/dist/{chunk-2FX5W4F5.js → chunk-YBOXRDQQ.js} +4 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +3 -3
- package/dist/mswPlugin.d.ts +2 -1
- package/dist/mswPlugin.js +3 -3
- package/dist/mswState.d.ts +2 -1
- package/dist/mswState.js +1 -1
- package/dist/requestHandlerRegistry.js +2 -2
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @squide/msw
|
|
2
2
|
|
|
3
|
+
## 3.2.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#221](https://github.com/gsoft-inc/wl-squide/pull/221) [`8411080`](https://github.com/gsoft-inc/wl-squide/commit/8411080dfd0df6d0eafb01888298154fa5e5d925) Thanks [@patricklafrance](https://github.com/patricklafrance)! - Fix deferred registrations.
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`8411080`](https://github.com/gsoft-inc/wl-squide/commit/8411080dfd0df6d0eafb01888298154fa5e5d925)]:
|
|
10
|
+
- @squide/core@5.4.1
|
|
11
|
+
|
|
12
|
+
## 3.2.0
|
|
13
|
+
|
|
14
|
+
### Minor Changes
|
|
15
|
+
|
|
16
|
+
- [#219](https://github.com/gsoft-inc/wl-squide/pull/219) [`25cb482`](https://github.com/gsoft-inc/wl-squide/commit/25cb482779ee280f3f7109de4607b92dcfeef7f3) Thanks [@patricklafrance](https://github.com/patricklafrance)! - Now dispatching events to enable instrumentation packages for observability platforms.
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- Updated dependencies [[`25cb482`](https://github.com/gsoft-inc/wl-squide/commit/25cb482779ee280f3f7109de4607b92dcfeef7f3)]:
|
|
21
|
+
- @squide/core@5.4.0
|
|
22
|
+
|
|
3
23
|
## 3.1.1
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { RequestHandlerRegistry } from './chunk-
|
|
1
|
+
import { RequestHandlerRegistry } from './chunk-CL6F3JZI.js';
|
|
2
2
|
import { Plugin, isNil } from '@squide/core';
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var MswPluginName = "msw-plugin";
|
|
5
|
+
var MswPlugin = class extends Plugin {
|
|
5
6
|
#requestHandlerRegistry = new RequestHandlerRegistry();
|
|
6
7
|
constructor(runtime) {
|
|
7
|
-
super(
|
|
8
|
+
super(MswPluginName, runtime);
|
|
8
9
|
}
|
|
9
10
|
registerRequestHandlers(handlers) {
|
|
10
11
|
this.#requestHandlerRegistry.add(handlers);
|
|
@@ -15,11 +16,11 @@ var MswPlugin = class _MswPlugin extends Plugin {
|
|
|
15
16
|
}
|
|
16
17
|
};
|
|
17
18
|
function getMswPlugin(runtime) {
|
|
18
|
-
const plugin = runtime.getPlugin(
|
|
19
|
+
const plugin = runtime.getPlugin(MswPluginName);
|
|
19
20
|
if (isNil(plugin)) {
|
|
20
21
|
throw new Error("[squide] The getMswPlugin function is called but no MswPlugin instance has been registered with the runtime.");
|
|
21
22
|
}
|
|
22
23
|
return plugin;
|
|
23
24
|
}
|
|
24
25
|
|
|
25
|
-
export { MswPlugin, getMswPlugin };
|
|
26
|
+
export { MswPlugin, MswPluginName, getMswPlugin };
|
|
@@ -30,6 +30,9 @@ function getMswState() {
|
|
|
30
30
|
function __setMswState(state) {
|
|
31
31
|
mswState = state;
|
|
32
32
|
}
|
|
33
|
+
function __clearMswState() {
|
|
34
|
+
mswState = void 0;
|
|
35
|
+
}
|
|
33
36
|
function setMswAsReady() {
|
|
34
37
|
getMswState().setAsReady();
|
|
35
38
|
}
|
|
@@ -43,4 +46,4 @@ function removeMswStateChangedListener(callback) {
|
|
|
43
46
|
getMswState().removeStateChangedListener(callback);
|
|
44
47
|
}
|
|
45
48
|
|
|
46
|
-
export { MswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady };
|
|
49
|
+
export { MswState, __clearMswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { MswPlugin, getMswPlugin } from './mswPlugin.js';
|
|
2
|
-
export { MswState, MswStateChangedListener, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './mswState.js';
|
|
1
|
+
export { MswPlugin, MswPluginName, getMswPlugin } from './mswPlugin.js';
|
|
2
|
+
export { MswState, MswStateChangedListener, __clearMswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './mswState.js';
|
|
3
3
|
export { RequestHandlerRegistry } from './requestHandlerRegistry.js';
|
|
4
4
|
import '@squide/core';
|
|
5
5
|
import 'msw';
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { MswPlugin, getMswPlugin } from './chunk-
|
|
2
|
-
export { RequestHandlerRegistry } from './chunk-
|
|
3
|
-
export { MswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './chunk-
|
|
1
|
+
export { MswPlugin, MswPluginName, getMswPlugin } from './chunk-NDT73ZLW.js';
|
|
2
|
+
export { RequestHandlerRegistry } from './chunk-CL6F3JZI.js';
|
|
3
|
+
export { MswState, __clearMswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './chunk-YBOXRDQQ.js';
|
package/dist/mswPlugin.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Plugin, Runtime } from '@squide/core';
|
|
2
2
|
import { RequestHandler } from 'msw';
|
|
3
3
|
|
|
4
|
+
declare const MswPluginName = "msw-plugin";
|
|
4
5
|
declare class MswPlugin extends Plugin {
|
|
5
6
|
#private;
|
|
6
7
|
constructor(runtime: Runtime);
|
|
@@ -9,4 +10,4 @@ declare class MswPlugin extends Plugin {
|
|
|
9
10
|
}
|
|
10
11
|
declare function getMswPlugin(runtime: Runtime): MswPlugin;
|
|
11
12
|
|
|
12
|
-
export { MswPlugin, getMswPlugin };
|
|
13
|
+
export { MswPlugin, MswPluginName, getMswPlugin };
|
package/dist/mswPlugin.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { MswPlugin, getMswPlugin } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
import './chunk-
|
|
1
|
+
export { MswPlugin, MswPluginName, getMswPlugin } from './chunk-NDT73ZLW.js';
|
|
2
|
+
import './chunk-CL6F3JZI.js';
|
|
3
|
+
import './chunk-YBOXRDQQ.js';
|
package/dist/mswState.d.ts
CHANGED
|
@@ -7,9 +7,10 @@ declare class MswState {
|
|
|
7
7
|
get isReady(): boolean;
|
|
8
8
|
}
|
|
9
9
|
declare function __setMswState(state: MswState): void;
|
|
10
|
+
declare function __clearMswState(): void;
|
|
10
11
|
declare function setMswAsReady(): void;
|
|
11
12
|
declare function isMswReady(): boolean;
|
|
12
13
|
declare function addMswStateChangedListener(callback: MswStateChangedListener): void;
|
|
13
14
|
declare function removeMswStateChangedListener(callback: MswStateChangedListener): void;
|
|
14
15
|
|
|
15
|
-
export { MswState, type MswStateChangedListener, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady };
|
|
16
|
+
export { MswState, type MswStateChangedListener, __clearMswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady };
|
package/dist/mswState.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { MswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './chunk-
|
|
1
|
+
export { MswState, __clearMswState, __setMswState, addMswStateChangedListener, isMswReady, removeMswStateChangedListener, setMswAsReady } from './chunk-YBOXRDQQ.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { RequestHandlerRegistry } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { RequestHandlerRegistry } from './chunk-CL6F3JZI.js';
|
|
2
|
+
import './chunk-YBOXRDQQ.js';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@squide/msw",
|
|
3
3
|
"author": "Workleap",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.2.1",
|
|
5
5
|
"description": "Add support for MSW to @squide application shell.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"repository": {
|
|
@@ -37,20 +37,20 @@
|
|
|
37
37
|
}
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
|
-
"@types/react": "18.3.
|
|
41
|
-
"@types/react-dom": "18.3.
|
|
42
|
-
"@workleap/eslint-plugin": "3.2.
|
|
40
|
+
"@types/react": "18.3.12",
|
|
41
|
+
"@types/react-dom": "18.3.1",
|
|
42
|
+
"@workleap/eslint-plugin": "3.2.3",
|
|
43
43
|
"@workleap/tsup-configs": "3.0.6",
|
|
44
44
|
"@workleap/typescript-configs": "3.0.2",
|
|
45
45
|
"eslint": "8.57.0",
|
|
46
|
-
"msw": "2.
|
|
46
|
+
"msw": "2.5.2",
|
|
47
47
|
"react": "18.3.1",
|
|
48
48
|
"react-dom": "18.3.1",
|
|
49
|
-
"tsup": "8.3.
|
|
49
|
+
"tsup": "8.3.5",
|
|
50
50
|
"typescript": "5.5.4"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@squide/core": "5.
|
|
53
|
+
"@squide/core": "5.4.1"
|
|
54
54
|
},
|
|
55
55
|
"sideEffects": false,
|
|
56
56
|
"engines": {
|