@tarojs/runtime 3.5.0-canary.1 → 3.5.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/dist/bom/document.d.ts +2 -3
- package/dist/bom/getComputedStyle.d.ts +3 -3
- package/dist/bom/navigator.d.ts +1 -15
- package/dist/bom/raf.d.ts +5 -4
- package/dist/bom/window.d.ts +2 -1
- package/dist/constants/index.d.ts +47 -47
- package/dist/current.d.ts +19 -17
- package/dist/dom/class-list.d.ts +14 -14
- package/dist/dom/document.d.ts +20 -17
- package/dist/dom/element.d.ts +38 -37
- package/dist/dom/event-source.d.ts +7 -7
- package/dist/dom/event-target.d.ts +7 -9
- package/dist/dom/event.d.ts +22 -26
- package/dist/dom/form.d.ts +7 -7
- package/dist/dom/node.d.ts +75 -79
- package/dist/dom/node_types.d.ts +10 -10
- package/dist/dom/root.d.ts +15 -15
- package/dist/dom/style.d.ts +14 -13
- package/dist/dom/style_properties.d.ts +3 -3
- package/dist/dom/svg.d.ts +3 -3
- package/dist/dom/text.d.ts +14 -13
- package/dist/dom/tree.d.ts +4 -4
- package/dist/dom-external/element.d.ts +3 -4
- package/dist/dom-external/index.d.ts +1 -0
- package/dist/dom-external/inner-html/html.d.ts +2 -3
- package/dist/dom-external/inner-html/parser.d.ts +25 -25
- package/dist/dom-external/inner-html/scaner.d.ts +30 -30
- package/dist/dom-external/inner-html/style.d.ts +27 -27
- package/dist/dom-external/inner-html/tags.d.ts +8 -8
- package/dist/dom-external/inner-html/utils.d.ts +1 -1
- package/dist/dom-external/mutation-observer/implements.d.ts +52 -52
- package/dist/dom-external/mutation-observer/index.d.ts +13 -12
- package/dist/dom-external/mutation-observer/record.d.ts +24 -24
- package/dist/dom-external/node.d.ts +11 -12
- package/dist/dsl/common.d.ts +15 -15
- package/dist/dsl/instance.d.ts +85 -82
- package/dist/emitter/emitter.d.ts +4 -29
- package/dist/env.d.ts +7 -2
- package/dist/hydrate.d.ts +10 -10
- package/dist/index.d.ts +26 -29
- package/dist/interface/element.d.ts +4 -4
- package/dist/interface/event-target.d.ts +10 -10
- package/dist/interface/event.d.ts +15 -15
- package/dist/interface/hydrate.d.ts +30 -29
- package/dist/interface/index.d.ts +7 -10
- package/dist/interface/node.d.ts +7 -7
- package/dist/interface/options.d.ts +16 -16
- package/dist/interface/utils.d.ts +2 -2
- package/dist/next-tick.d.ts +2 -2
- package/dist/options.d.ts +2 -2
- package/dist/perf.d.ts +7 -7
- package/dist/runtime.esm.d.ts +537 -0
- package/dist/runtime.esm.js +3146 -4650
- package/dist/runtime.esm.js.map +1 -1
- package/dist/utils/index.d.ts +23 -16
- package/package.json +10 -16
- package/dist/constants/events.d.ts +0 -5
- package/dist/constants/identifiers.d.ts +0 -61
- package/dist/container/default-hooks.d.ts +0 -4
- package/dist/container/index.d.ts +0 -3
- package/dist/container/plugin-hooks.d.ts +0 -2
- package/dist/container/store.d.ts +0 -15
- package/dist/dom-external/element-impl.d.ts +0 -4
- package/dist/dom-external/node-impl.d.ts +0 -8
- package/dist/hooks.d.ts +0 -32
- package/dist/interface/container.d.ts +0 -12
- package/dist/interface/document.d.ts +0 -14
- package/dist/interface/hooks.d.ts +0 -162
package/dist/dsl/instance.d.ts
CHANGED
|
@@ -1,82 +1,85 @@
|
|
|
1
|
-
import type { Component
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import type { CombinedVueInstance } from 'vue/types/vue';
|
|
5
|
-
import type {
|
|
6
|
-
import type {
|
|
7
|
-
export interface Instance<T = Record<string, any>> extends Component<T>, Show, PageInstance {
|
|
8
|
-
tid?: string;
|
|
9
|
-
$forceUpdate?(): void;
|
|
10
|
-
$nextTick?(cb: () => void): void;
|
|
11
|
-
$options: Instance;
|
|
12
|
-
}
|
|
13
|
-
export interface VueAppInstance extends ComponentOptions<VueCtor> {
|
|
14
|
-
$options: AppInstance;
|
|
15
|
-
}
|
|
16
|
-
export declare type VueInstance<M = Record<string, any>, P = Record<string, any>> = CombinedVueInstance<VueCtor, Record<string, any>, M, P, Record<never, any>> & VueInternal;
|
|
17
|
-
interface VueInternal {
|
|
18
|
-
_render(): VNode;
|
|
19
|
-
_update(vnode: VNode, hyrate: boolean): void;
|
|
20
|
-
}
|
|
21
|
-
export interface PageProps {
|
|
22
|
-
tid?: string;
|
|
23
|
-
}
|
|
24
|
-
export interface ReactPageComponent<T = PageProps> extends ComponentClass<T>, PageInstance {
|
|
25
|
-
}
|
|
26
|
-
export interface ReactPageInstance<T = PageProps> extends Component<T>, PageInstance {
|
|
27
|
-
componentDidShow?(): void;
|
|
28
|
-
componentDidHide?(): void;
|
|
29
|
-
}
|
|
30
|
-
export interface ReactAppInstance<T = AppInstance> extends Component<T>, AppInstance {
|
|
31
|
-
}
|
|
32
|
-
export interface PageLifeCycle extends Show {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
1
|
+
import type { Component as Vue3Component } from '@vue/runtime-core';
|
|
2
|
+
import type { Component, ComponentClass } from 'react';
|
|
3
|
+
import VueCtor, { ComponentOptions, VNode } from 'vue';
|
|
4
|
+
import type { CombinedVueInstance } from 'vue/types/vue';
|
|
5
|
+
import type { TaroElement } from '../dom/element';
|
|
6
|
+
import type { Func, MpEvent } from '../interface';
|
|
7
|
+
export interface Instance<T = Record<string, any>> extends Component<T>, Show, PageInstance {
|
|
8
|
+
tid?: string;
|
|
9
|
+
$forceUpdate?(): void;
|
|
10
|
+
$nextTick?(cb: () => void): void;
|
|
11
|
+
$options: Instance;
|
|
12
|
+
}
|
|
13
|
+
export interface VueAppInstance extends ComponentOptions<VueCtor> {
|
|
14
|
+
$options: AppInstance;
|
|
15
|
+
}
|
|
16
|
+
export declare type VueInstance<M = Record<string, any>, P = Record<string, any>> = CombinedVueInstance<VueCtor, Record<string, any>, M, P, Record<never, any>> & VueInternal;
|
|
17
|
+
interface VueInternal {
|
|
18
|
+
_render(): VNode;
|
|
19
|
+
_update(vnode: VNode, hyrate: boolean): void;
|
|
20
|
+
}
|
|
21
|
+
export interface PageProps {
|
|
22
|
+
tid?: string;
|
|
23
|
+
}
|
|
24
|
+
export interface ReactPageComponent<T = PageProps> extends ComponentClass<T>, PageInstance {
|
|
25
|
+
}
|
|
26
|
+
export interface ReactPageInstance<T = PageProps> extends Component<T>, PageInstance {
|
|
27
|
+
componentDidShow?(): void;
|
|
28
|
+
componentDidHide?(): void;
|
|
29
|
+
}
|
|
30
|
+
export interface ReactAppInstance<T = AppInstance> extends Component<T>, AppInstance {
|
|
31
|
+
}
|
|
32
|
+
export interface PageLifeCycle extends Show {
|
|
33
|
+
eh?(event: MpEvent): void;
|
|
34
|
+
onAddToFavorites?(): void;
|
|
35
|
+
onLoad?(options: Record<string, unknown>, cb?: Func): void;
|
|
36
|
+
onOptionMenuClick?(): void;
|
|
37
|
+
onPageScroll?(obj: {
|
|
38
|
+
scrollTop: number;
|
|
39
|
+
}): void;
|
|
40
|
+
onPullDownRefresh?(): void;
|
|
41
|
+
onPullIntercept?(): void;
|
|
42
|
+
onPopMenuClick?(): void;
|
|
43
|
+
onReachBottom?(): void;
|
|
44
|
+
onReady?(): void;
|
|
45
|
+
onResize?(options: unknown): void;
|
|
46
|
+
onSaveExitState?(): void;
|
|
47
|
+
onShareAppMessage?(obj: {
|
|
48
|
+
from: string;
|
|
49
|
+
target?: TaroElement;
|
|
50
|
+
webViewUrl: string;
|
|
51
|
+
}): void;
|
|
52
|
+
onShareTimeline?(): void;
|
|
53
|
+
onTabItemTap?(obj: {
|
|
54
|
+
index: string;
|
|
55
|
+
pagePath: string;
|
|
56
|
+
text: string;
|
|
57
|
+
}): void;
|
|
58
|
+
onTitleClick?(): void;
|
|
59
|
+
onUnload?(): void;
|
|
60
|
+
}
|
|
61
|
+
export interface PageInstance extends PageLifeCycle {
|
|
62
|
+
/** 页面的初始数据 */
|
|
63
|
+
data?: Record<string, unknown>;
|
|
64
|
+
/** 页面路径 */
|
|
65
|
+
path?: string;
|
|
66
|
+
/** 页面的组件选项 */
|
|
67
|
+
options?: Record<string, unknown>;
|
|
68
|
+
}
|
|
69
|
+
interface Show {
|
|
70
|
+
componentDidShow?(): void;
|
|
71
|
+
componentDidHide?(): void;
|
|
72
|
+
onShow?(): void;
|
|
73
|
+
onHide?(): void;
|
|
74
|
+
}
|
|
75
|
+
export interface AppInstance extends Show {
|
|
76
|
+
componentDidShow?(options?: Record<string, unknown>): void;
|
|
77
|
+
mount?(component: React.ComponentClass | ComponentOptions<VueCtor> | Vue3Component, id: string, cb: (...args: any[]) => void): void;
|
|
78
|
+
onError?(error: string): void;
|
|
79
|
+
onLaunch?(options?: Record<string, unknown>): void;
|
|
80
|
+
onPageNotFound?(res: any): void;
|
|
81
|
+
onShow?(options?: Record<string, unknown>): void;
|
|
82
|
+
unmount?(id: string, cb?: () => void): void;
|
|
83
|
+
taroGlobalData?: Record<any, any>;
|
|
84
|
+
}
|
|
85
|
+
export {};
|
|
@@ -1,29 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
declare
|
|
3
|
-
declare type
|
|
4
|
-
|
|
5
|
-
declare type Callback5<T1, T2, T3, T4, T5> = (arg1: T1, arg2: T2, arg3: T3, arg4: T4, arg5: T5) => any;
|
|
6
|
-
declare type Callback6Rest<T1, T2, T3, T4, T5, T6> = (arg1: T1, arg2: T2, arg3: T3, arg4: T4, arg5: T5, arg6: T6, ...rest: any[]) => any;
|
|
7
|
-
export declare class Events {
|
|
8
|
-
private callbacks?;
|
|
9
|
-
static eventSplitter: RegExp;
|
|
10
|
-
constructor(opts?: any);
|
|
11
|
-
on<T>(event: string, callback: Callback1<T>, context: any): this;
|
|
12
|
-
on<T1, T2>(event: string, callback: Callback2<T1, T2>, context: any): this;
|
|
13
|
-
on<T1, T2, T3>(event: string, callback: Callback3<T1, T2, T3>, context: any): this;
|
|
14
|
-
on<T1, T2, T3, T4>(event: string, callback: Callback4<T1, T2, T3, T4>, comtext: any): this;
|
|
15
|
-
on<T1, T2, T3, T4, T5>(event: string, callback: Callback5<T1, T2, T3, T4, T5>, context: any): this;
|
|
16
|
-
on<T1, T2, T3, T4, T5, T6>(event: string, callback: Callback6Rest<T1, T2, T3, T4, T5, T6>, context: any): this;
|
|
17
|
-
once(events: any, callback: any, context: any): this;
|
|
18
|
-
off(events: any, callback: any, context: any): this;
|
|
19
|
-
trigger(event: string): any;
|
|
20
|
-
trigger<T1>(event: string, arg: T1): any;
|
|
21
|
-
trigger<T1, T2>(event: string, arg1: T1, arg2: T2): any;
|
|
22
|
-
trigger<T1, T2, T3>(event: string, arg1: T1, arg2: T2, arg3: T3): any;
|
|
23
|
-
trigger<T1, T2, T3, T4>(event: string, arg1: T1, arg2: T2, arg3: T3, arg4: T4): any;
|
|
24
|
-
trigger<T1, T2, T3, T4, T5>(event: string, arg1: T1, arg2: T2, arg3: T3, arg4: T4, arg5: T5): any;
|
|
25
|
-
trigger<T1, T2, T3, T4, T5, T6>(event: string, arg1: T1, arg2: T2, arg3: T3, arg4: T4, arg5: T5, arg6: T6, ...rest: any[]): any;
|
|
26
|
-
}
|
|
27
|
-
export declare type EventsType = typeof Events;
|
|
28
|
-
declare const eventCenter: Events;
|
|
29
|
-
export { eventCenter };
|
|
1
|
+
import { Events } from '@tarojs/shared';
|
|
2
|
+
declare const eventCenter: Events;
|
|
3
|
+
export declare type EventsType = typeof Events;
|
|
4
|
+
export { eventCenter, Events };
|
package/dist/env.d.ts
CHANGED
package/dist/hydrate.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type {
|
|
4
|
-
/**
|
|
5
|
-
* React also has a fancy function's name for this: `hydrate()`.
|
|
6
|
-
* You may have been heard `hydrate` as a SSR-related function,
|
|
7
|
-
* actually, `hydrate` basicly do the `render()` thing, but ignore some properties,
|
|
8
|
-
* it's a vnode traverser and modifier: that's exactly what Taro's doing in here.
|
|
9
|
-
*/
|
|
10
|
-
export declare function hydrate(node: TaroElement | TaroText): MiniData;
|
|
1
|
+
import type { TaroElement } from './dom/element';
|
|
2
|
+
import type { TaroText } from './dom/text';
|
|
3
|
+
import type { MiniData } from './interface';
|
|
4
|
+
/**
|
|
5
|
+
* React also has a fancy function's name for this: `hydrate()`.
|
|
6
|
+
* You may have been heard `hydrate` as a SSR-related function,
|
|
7
|
+
* actually, `hydrate` basicly do the `render()` thing, but ignore some properties,
|
|
8
|
+
* it's a vnode traverser and modifier: that's exactly what Taro's doing in here.
|
|
9
|
+
*/
|
|
10
|
+
export declare function hydrate(node: TaroElement | TaroText): MiniData;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,29 +1,26 @@
|
|
|
1
|
-
import './
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
6
|
-
export {
|
|
7
|
-
export {
|
|
8
|
-
export {
|
|
9
|
-
export {
|
|
10
|
-
export {
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
13
|
-
export {
|
|
14
|
-
export {
|
|
15
|
-
export {
|
|
16
|
-
export {
|
|
17
|
-
export
|
|
18
|
-
export {
|
|
19
|
-
export {
|
|
20
|
-
export
|
|
21
|
-
export {
|
|
22
|
-
export { nextTick } from './next-tick';
|
|
23
|
-
export {
|
|
24
|
-
export
|
|
25
|
-
export
|
|
26
|
-
export
|
|
27
|
-
export * from './interface';
|
|
28
|
-
export { incrementId } from './utils';
|
|
29
|
-
export { eventSource } from './dom/event-source';
|
|
1
|
+
import './dom-external';
|
|
2
|
+
export { hooks } from '@tarojs/shared';
|
|
3
|
+
export { document } from './bom/document';
|
|
4
|
+
export { getComputedStyle } from './bom/getComputedStyle';
|
|
5
|
+
export { nav as navigator } from './bom/navigator';
|
|
6
|
+
export { caf as cancelAnimationFrame, now, raf as requestAnimationFrame } from './bom/raf';
|
|
7
|
+
export { window } from './bom/window';
|
|
8
|
+
export { TaroElement } from './dom/element';
|
|
9
|
+
export { createEvent, eventHandler, TaroEvent } from './dom/event';
|
|
10
|
+
export { FormElement } from './dom/form';
|
|
11
|
+
export { TaroNode } from './dom/node';
|
|
12
|
+
export { TaroRootElement } from './dom/root';
|
|
13
|
+
export { Style } from './dom/style';
|
|
14
|
+
export { SVGElement } from './dom/svg';
|
|
15
|
+
export { TaroText } from './dom/text';
|
|
16
|
+
export { MutationObserver } from './dom-external/mutation-observer';
|
|
17
|
+
export { Current, getCurrentInstance } from './current';
|
|
18
|
+
export { eventSource } from './dom/event-source';
|
|
19
|
+
export { addLeadingSlash, createComponentConfig, createPageConfig, createRecursiveComponentConfig, getPageInstance, injectPageInstance, safeExecute, stringify } from './dsl/common';
|
|
20
|
+
export * from './emitter/emitter';
|
|
21
|
+
export { hydrate } from './hydrate';
|
|
22
|
+
export { nextTick } from './next-tick';
|
|
23
|
+
export { options } from './options';
|
|
24
|
+
export { incrementId } from './utils';
|
|
25
|
+
export * from './dsl/instance';
|
|
26
|
+
export * from './interface';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export interface Attributes {
|
|
2
|
-
name: string;
|
|
3
|
-
value: string;
|
|
4
|
-
}
|
|
1
|
+
export interface Attributes {
|
|
2
|
+
name: string;
|
|
3
|
+
value: string;
|
|
4
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export interface EventListenerOptions {
|
|
2
|
-
capture?: boolean;
|
|
3
|
-
}
|
|
4
|
-
export interface AddEventListenerOptions extends EventListenerOptions {
|
|
5
|
-
once?: boolean;
|
|
6
|
-
passive?: boolean;
|
|
7
|
-
}
|
|
8
|
-
export interface EventHandler extends Function {
|
|
9
|
-
_stop?: boolean;
|
|
10
|
-
}
|
|
1
|
+
export interface EventListenerOptions {
|
|
2
|
+
capture?: boolean;
|
|
3
|
+
}
|
|
4
|
+
export interface AddEventListenerOptions extends EventListenerOptions {
|
|
5
|
+
once?: boolean;
|
|
6
|
+
passive?: boolean;
|
|
7
|
+
}
|
|
8
|
+
export interface EventHandler extends Function {
|
|
9
|
+
_stop?: boolean;
|
|
10
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
export interface EventOptions {
|
|
2
|
-
bubbles: boolean;
|
|
3
|
-
cancelable: boolean;
|
|
4
|
-
}
|
|
5
|
-
declare type Target = Record<string, unknown> & {
|
|
6
|
-
dataset: Record<string, unknown>;
|
|
7
|
-
id: string;
|
|
8
|
-
};
|
|
9
|
-
export interface MpEvent {
|
|
10
|
-
type: string;
|
|
11
|
-
detail: Record<string, unknown>;
|
|
12
|
-
target: Target;
|
|
13
|
-
currentTarget: Target;
|
|
14
|
-
}
|
|
15
|
-
export {};
|
|
1
|
+
export interface EventOptions {
|
|
2
|
+
bubbles: boolean;
|
|
3
|
+
cancelable: boolean;
|
|
4
|
+
}
|
|
5
|
+
declare type Target = Record<string, unknown> & {
|
|
6
|
+
dataset: Record<string, unknown>;
|
|
7
|
+
id: string;
|
|
8
|
+
};
|
|
9
|
+
export interface MpEvent {
|
|
10
|
+
type: string;
|
|
11
|
+
detail: Record<string, unknown>;
|
|
12
|
+
target: Target;
|
|
13
|
+
currentTarget: Target;
|
|
14
|
+
}
|
|
15
|
+
export {};
|
|
@@ -1,29 +1,30 @@
|
|
|
1
|
-
import type { Shortcuts } from '@tarojs/shared';
|
|
2
|
-
import type { PageConfig } from '@tarojs/taro';
|
|
3
|
-
export interface MpInstance {
|
|
4
|
-
config: PageConfig;
|
|
5
|
-
setData: (data: unknown, cb: () => void) => void;
|
|
6
|
-
route?: string;
|
|
7
|
-
__route__: string;
|
|
8
|
-
$taroParams?: Record<string, unknown>;
|
|
9
|
-
$taroPath: string;
|
|
10
|
-
__data__: any;
|
|
11
|
-
data: any;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
[Shortcuts.
|
|
17
|
-
[Shortcuts.
|
|
18
|
-
[Shortcuts.
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
[Shortcuts.
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
export declare type
|
|
29
|
-
export
|
|
1
|
+
import type { Shortcuts } from '@tarojs/shared';
|
|
2
|
+
import type { PageConfig } from '@tarojs/taro';
|
|
3
|
+
export interface MpInstance {
|
|
4
|
+
config: PageConfig;
|
|
5
|
+
setData: (data: unknown, cb: () => void) => void;
|
|
6
|
+
route?: string;
|
|
7
|
+
__route__: string;
|
|
8
|
+
$taroParams?: Record<string, unknown>;
|
|
9
|
+
$taroPath: string;
|
|
10
|
+
__data__: any;
|
|
11
|
+
data: any;
|
|
12
|
+
exitState?: any;
|
|
13
|
+
selectComponent: (selector: string) => any;
|
|
14
|
+
}
|
|
15
|
+
export interface MiniElementData {
|
|
16
|
+
[Shortcuts.Childnodes]?: MiniData[];
|
|
17
|
+
[Shortcuts.NodeName]: string;
|
|
18
|
+
[Shortcuts.Class]?: string;
|
|
19
|
+
[Shortcuts.Style]?: string;
|
|
20
|
+
uid?: string;
|
|
21
|
+
sid: string;
|
|
22
|
+
[key: string]: unknown;
|
|
23
|
+
}
|
|
24
|
+
interface MiniTextData {
|
|
25
|
+
[Shortcuts.Text]: string;
|
|
26
|
+
[Shortcuts.NodeName]: string;
|
|
27
|
+
}
|
|
28
|
+
export declare type MiniData = MiniElementData | MiniTextData;
|
|
29
|
+
export declare type HydratedData = () => MiniData | MiniData[];
|
|
30
|
+
export {};
|
|
@@ -1,10 +1,7 @@
|
|
|
1
|
-
export * from './
|
|
2
|
-
export * from './
|
|
3
|
-
export * from './
|
|
4
|
-
export * from './
|
|
5
|
-
export * from './
|
|
6
|
-
export * from './
|
|
7
|
-
export * from './
|
|
8
|
-
export * from './options';
|
|
9
|
-
export * from './utils';
|
|
10
|
-
export * from './hooks';
|
|
1
|
+
export * from './element';
|
|
2
|
+
export * from './event';
|
|
3
|
+
export * from './event-target';
|
|
4
|
+
export * from './hydrate';
|
|
5
|
+
export * from './node';
|
|
6
|
+
export * from './options';
|
|
7
|
+
export * from './utils';
|
package/dist/interface/node.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { HydratedData } from './index';
|
|
2
|
-
export declare type UpdatePayloadValue = string | boolean | HydratedData;
|
|
3
|
-
export declare type DataTree = Record<string, UpdatePayloadValue | ReturnType<HydratedData>>;
|
|
4
|
-
export interface UpdatePayload {
|
|
5
|
-
path: string;
|
|
6
|
-
value: UpdatePayloadValue;
|
|
7
|
-
}
|
|
1
|
+
import { HydratedData } from './index';
|
|
2
|
+
export declare type UpdatePayloadValue = string | boolean | HydratedData;
|
|
3
|
+
export declare type DataTree = Record<string, UpdatePayloadValue | ReturnType<HydratedData>>;
|
|
4
|
+
export interface UpdatePayload {
|
|
5
|
+
path: string;
|
|
6
|
+
value: UpdatePayloadValue;
|
|
7
|
+
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type {
|
|
4
|
-
export interface Options {
|
|
5
|
-
prerender: boolean;
|
|
6
|
-
debug: boolean;
|
|
7
|
-
html?: {
|
|
8
|
-
skipElements: Set<string>;
|
|
9
|
-
voidElements: Set<string>;
|
|
10
|
-
closingElements: Set<string>;
|
|
11
|
-
transformText?: (taroText: TaroText, text: Text) => TaroText;
|
|
12
|
-
transformElement?: (taroElement: TaroElement, element: Element) => TaroElement;
|
|
13
|
-
renderHTMLTag: boolean;
|
|
14
|
-
};
|
|
15
|
-
miniGlobal?: any;
|
|
16
|
-
}
|
|
1
|
+
import type { TaroElement } from '../dom/element';
|
|
2
|
+
import type { TaroText } from '../dom/text';
|
|
3
|
+
import type { Element, Text } from '../dom-external/inner-html/parser';
|
|
4
|
+
export interface Options {
|
|
5
|
+
prerender: boolean;
|
|
6
|
+
debug: boolean;
|
|
7
|
+
html?: {
|
|
8
|
+
skipElements: Set<string>;
|
|
9
|
+
voidElements: Set<string>;
|
|
10
|
+
closingElements: Set<string>;
|
|
11
|
+
transformText?: (taroText: TaroText, text: Text) => TaroText;
|
|
12
|
+
transformElement?: (taroElement: TaroElement, element: Element) => TaroElement;
|
|
13
|
+
renderHTMLTag: boolean;
|
|
14
|
+
};
|
|
15
|
+
miniGlobal?: any;
|
|
16
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare type Func = (...args: any[]) => any;
|
|
2
|
-
export declare type Ctx = Record<string, any>;
|
|
1
|
+
export declare type Func = (...args: any[]) => any;
|
|
2
|
+
export declare type Ctx = Record<string, any>;
|
package/dist/next-tick.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { Func } from './interface';
|
|
2
|
-
export declare const nextTick: (cb: Func, ctx?: Record<string, any>
|
|
1
|
+
import type { Func } from './interface';
|
|
2
|
+
export declare const nextTick: (cb: Func, ctx?: Record<string, any>) => void;
|
package/dist/options.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { Options } from './interface';
|
|
2
|
-
export declare const options: Options;
|
|
1
|
+
import type { Options } from './interface';
|
|
2
|
+
export declare const options: Options;
|
package/dist/perf.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
declare class Performance {
|
|
2
|
-
private recorder;
|
|
3
|
-
start(id: string): void;
|
|
4
|
-
stop(id: string): void;
|
|
5
|
-
}
|
|
6
|
-
export declare const perf: Performance;
|
|
7
|
-
export {};
|
|
1
|
+
declare class Performance {
|
|
2
|
+
private recorder;
|
|
3
|
+
start(id: string): void;
|
|
4
|
+
stop(id: string): void;
|
|
5
|
+
}
|
|
6
|
+
export declare const perf: Performance;
|
|
7
|
+
export {};
|