@ibiz-template/core 0.2.15 → 0.2.18-dev.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.
@@ -1,4 +1,4 @@
1
- export { ICommand, Command, ICommandHandler, ICommandsMap, ICommandRegistry, } from './command/command';
2
- export { ICommandOption } from './command/command-option';
3
- export { IDisposable } from './disposable/disposable';
1
+ export type { ICommand, Command, ICommandHandler, ICommandsMap, ICommandRegistry, } from './command/command';
2
+ export type { ICommandOption } from './command/command-option';
3
+ export type { IDisposable } from './disposable/disposable';
4
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/command/interface/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,OAAO,EACP,eAAe,EACf,YAAY,EACZ,gBAAgB,GACjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/command/interface/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,QAAQ,EACR,OAAO,EACP,eAAe,EACf,YAAY,EACZ,gBAAgB,GACjB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,YAAY,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC"}
@@ -1,7 +1,8 @@
1
1
  export * from './interceptor';
2
2
  export { MessageCenter } from './message-center';
3
3
  export { Namespace } from './namespace/namespace';
4
- export { IHttpResponse, HttpResponse } from './net/http-response';
4
+ export type { IHttpResponse } from './net/http-response';
5
+ export { HttpResponse } from './net/http-response';
5
6
  export { Net } from './net/net';
6
7
  export { StringUtil } from './string-util/string-util';
7
8
  export * from './util/util';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAClE,OAAO,EAAE,GAAG,EAAE,MAAM,WAAW,CAAC;AAChC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,eAAe,CAAC;AAC9B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,QAAQ,CAAC;AACvB,cAAc,sBAAsB,CAAC;AACrC,cAAc,kCAAkC,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,GAAG,EAAE,MAAM,WAAW,CAAC;AAChC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,eAAe,CAAC;AAC9B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,QAAQ,CAAC;AACvB,cAAc,sBAAsB,CAAC;AACrC,cAAc,kCAAkC,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC"}
@@ -1,5 +1,5 @@
1
- import * as Logger from 'loglevel';
2
- import * as prefix from 'loglevel-plugin-prefix';
1
+ import Logger from 'loglevel';
2
+ import prefix from 'loglevel-plugin-prefix';
3
3
  const logger = Logger.noConflict();
4
4
  prefix.reg(logger);
5
5
  prefix.apply(logger);
@@ -1 +1 @@
1
- {"version":3,"file":"http-response.d.ts","sourceRoot":"","sources":["../../../src/utils/net/http-response.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,aAAa,EACb,oBAAoB,EACpB,0BAA0B,EAC1B,uBAAuB,EACxB,MAAM,OAAO,CAAC;AAEf;;;;;;;;;GASG;AACH,MAAM,WAAW,aAAa,CAAC,CAAC,GAAG,KAAK,CAAE,SAAQ,aAAa;IAC7D;;;;;;;OAOG;IACH,EAAE,EAAE,OAAO,CAAC;IACZ;;;;;;;OAOG;IACH,KAAK,EAAE,OAAO,CAAC;IAEf,IAAI,EAAE,CAAC,CAAC;IAER;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;;;GASG;AACH,qBAAa,YAAY,CAAC,CAAC,GAAG,KAAK,CAAE,YAAW,aAAa,CAAC,CAAC,CAAC;IAC9D;;;;;OA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;;;;;;OAQG;gBACS,IAAI,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM;CAQjE"}
@@ -1,4 +1,4 @@
1
- import { AxiosHeaders, } from 'axios';
1
+ import axios from 'axios';
2
2
  /**
3
3
  * 本地请求仿造响应
4
4
  *
@@ -30,7 +30,7 @@ export class HttpResponse {
30
30
  this.ok = false;
31
31
  this.headers = {};
32
32
  this.config = {
33
- headers: new AxiosHeaders(),
33
+ headers: new axios.AxiosHeaders(),
34
34
  };
35
35
  this.data = data;
36
36
  this.status = status || 200;
@@ -1,7 +1,7 @@
1
1
  import axios from 'axios';
2
2
  import { fetchEventSource, } from '@microsoft/fetch-event-source';
3
3
  import { merge } from 'lodash-es';
4
- import { stringify } from 'qs';
4
+ import qs from 'qs';
5
5
  import { notNilEmpty } from 'qx-util';
6
6
  import { mergeDeepRight } from 'ramda';
7
7
  import { HttpError } from '../../error';
@@ -376,7 +376,7 @@ export class Net {
376
376
  .join('/');
377
377
  url = urlSplit.length > 1 ? urlSplit.join('?') : urlSplit[0];
378
378
  }
379
- const strParams = stringify(params);
379
+ const strParams = qs.stringify(params);
380
380
  if (notNilEmpty(strParams)) {
381
381
  if (url.endsWith('?')) {
382
382
  url = `${url}${strParams}`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ibiz-template/core",
3
- "version": "0.2.15",
3
+ "version": "0.2.18-dev.1",
4
4
  "description": "核心包",
5
5
  "type": "module",
6
6
  "main": "out/index.js",
@@ -49,5 +49,6 @@
49
49
  "qs": "^6.11.0",
50
50
  "qx-util": "^0.4.8",
51
51
  "ramda": "^0.29.0"
52
- }
52
+ },
53
+ "gitHead": "a097e3cf18cdf9e3e04767d441f101f330eab149"
53
54
  }
@@ -1,9 +1,9 @@
1
- export {
1
+ export type {
2
2
  ICommand,
3
3
  Command,
4
4
  ICommandHandler,
5
5
  ICommandsMap,
6
6
  ICommandRegistry,
7
7
  } from './command/command';
8
- export { ICommandOption } from './command/command-option';
9
- export { IDisposable } from './disposable/disposable';
8
+ export type { ICommandOption } from './command/command-option';
9
+ export type { IDisposable } from './disposable/disposable';
@@ -1,7 +1,8 @@
1
1
  export * from './interceptor';
2
2
  export { MessageCenter } from './message-center';
3
3
  export { Namespace } from './namespace/namespace';
4
- export { IHttpResponse, HttpResponse } from './net/http-response';
4
+ export type { IHttpResponse } from './net/http-response';
5
+ export { HttpResponse } from './net/http-response';
5
6
  export { Net } from './net/net';
6
7
  export { StringUtil } from './string-util/string-util';
7
8
  export * from './util/util';
@@ -1,5 +1,5 @@
1
- import * as Logger from 'loglevel';
2
- import * as prefix from 'loglevel-plugin-prefix';
1
+ import Logger from 'loglevel';
2
+ import prefix from 'loglevel-plugin-prefix';
3
3
 
4
4
  const logger = Logger.noConflict();
5
5
 
@@ -1,5 +1,4 @@
1
- import {
2
- AxiosHeaders,
1
+ import axios, {
3
2
  AxiosResponse,
4
3
  AxiosResponseHeaders,
5
4
  InternalAxiosRequestConfig,
@@ -84,7 +83,7 @@ export class HttpResponse<T = IData> implements IHttpResponse<T> {
84
83
  headers: RawAxiosResponseHeaders | AxiosResponseHeaders = {};
85
84
 
86
85
  config: InternalAxiosRequestConfig<IData> = {
87
- headers: new AxiosHeaders(),
86
+ headers: new axios.AxiosHeaders(),
88
87
  };
89
88
 
90
89
  /**
@@ -11,7 +11,7 @@ import {
11
11
  fetchEventSource,
12
12
  } from '@microsoft/fetch-event-source';
13
13
  import { merge } from 'lodash-es';
14
- import { stringify } from 'qs';
14
+ import qs from 'qs';
15
15
  import { notNilEmpty } from 'qx-util';
16
16
  import { mergeDeepRight } from 'ramda';
17
17
  import { HttpError } from '../../error';
@@ -448,7 +448,7 @@ export class Net {
448
448
  .join('/');
449
449
  url = urlSplit.length > 1 ? urlSplit.join('?') : urlSplit[0];
450
450
  }
451
- const strParams: string = stringify(params);
451
+ const strParams: string = qs.stringify(params);
452
452
  if (notNilEmpty(strParams)) {
453
453
  if (url.endsWith('?')) {
454
454
  url = `${url}${strParams}`;