@faiwer/react 19.0.1 → 19.0.3
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.md +38 -16
- package/dist/core/actions/helpers.d.ts +6 -1
- package/dist/core/actions/helpers.d.ts.map +1 -1
- package/dist/core/actions/helpers.js +19 -1
- package/dist/core/actions/helpers.js.map +1 -1
- package/dist/core/actions/remove.action.d.ts.map +1 -1
- package/dist/core/actions/remove.action.js +2 -0
- package/dist/core/actions/remove.action.js.map +1 -1
- package/dist/core/components.d.ts.map +1 -1
- package/dist/core/components.js +9 -1
- package/dist/core/components.js.map +1 -1
- package/dist/core/createElement.d.ts +5 -1
- package/dist/core/createElement.d.ts.map +1 -1
- package/dist/core/createElement.js +25 -1
- package/dist/core/createElement.js.map +1 -1
- package/dist/core/devTools/devTools.d.ts +2 -0
- package/dist/core/devTools/devTools.d.ts.map +1 -0
- package/dist/core/devTools/devTools.js +46 -0
- package/dist/core/devTools/devTools.js.map +1 -0
- package/dist/core/devTools/hmr.d.ts +6 -0
- package/dist/core/devTools/hmr.d.ts.map +1 -0
- package/dist/core/devTools/hmr.js +55 -0
- package/dist/core/devTools/hmr.js.map +1 -0
- package/dist/core/devTools/toRFiber.d.ts +7 -0
- package/dist/core/devTools/toRFiber.d.ts.map +1 -0
- package/dist/core/devTools/toRFiber.js +130 -0
- package/dist/core/devTools/toRFiber.js.map +1 -0
- package/dist/core/devTools/toRJsx.d.ts +10 -0
- package/dist/core/devTools/toRJsx.d.ts.map +1 -0
- package/dist/core/devTools/toRJsx.js +62 -0
- package/dist/core/devTools/toRJsx.js.map +1 -0
- package/dist/core/devTools/types.d.ts +154 -0
- package/dist/core/devTools/types.d.ts.map +1 -0
- package/dist/core/devTools/types.js +19 -0
- package/dist/core/devTools/types.js.map +1 -0
- package/dist/core/preact/connect.d.ts +3 -0
- package/dist/core/preact/connect.d.ts.map +1 -0
- package/dist/core/preact/connect.js +162 -0
- package/dist/core/preact/connect.js.map +1 -0
- package/dist/core/preact/helpers.d.ts +12 -0
- package/dist/core/preact/helpers.d.ts.map +1 -0
- package/dist/core/preact/helpers.js +52 -0
- package/dist/core/preact/helpers.js.map +1 -0
- package/dist/core/preact/inspect.d.ts +9 -0
- package/dist/core/preact/inspect.d.ts.map +1 -0
- package/dist/core/preact/inspect.js +169 -0
- package/dist/core/preact/inspect.js.map +1 -0
- package/dist/core/preact/toVNode.d.ts +11 -0
- package/dist/core/preact/toVNode.d.ts.map +1 -0
- package/dist/core/preact/toVNode.js +150 -0
- package/dist/core/preact/toVNode.js.map +1 -0
- package/dist/core/preact/types.d.ts +180 -0
- package/dist/core/preact/types.d.ts.map +1 -0
- package/dist/core/preact/types.js +29 -0
- package/dist/core/preact/types.js.map +1 -0
- package/dist/core/preact/update.d.ts +13 -0
- package/dist/core/preact/update.d.ts.map +1 -0
- package/dist/core/preact/update.js +40 -0
- package/dist/core/preact/update.js.map +1 -0
- package/dist/core/reactNodeToFiberNode.d.ts.map +1 -1
- package/dist/core/reactNodeToFiberNode.js +10 -2
- package/dist/core/reactNodeToFiberNode.js.map +1 -1
- package/dist/core/reconciliation/applyActions.d.ts.map +1 -1
- package/dist/core/reconciliation/applyActions.js +1 -0
- package/dist/core/reconciliation/applyActions.js.map +1 -1
- package/dist/core/reconciliation/collect/fromApp.d.ts.map +1 -1
- package/dist/core/reconciliation/collect/fromApp.js +10 -1
- package/dist/core/reconciliation/collect/fromApp.js.map +1 -1
- package/dist/core/reconciliation/compare/areFiberNodesEq.d.ts.map +1 -1
- package/dist/core/reconciliation/compare/areFiberNodesEq.js +4 -0
- package/dist/core/reconciliation/compare/areFiberNodesEq.js.map +1 -1
- package/dist/core/reconciliation/effects.d.ts.map +1 -1
- package/dist/core/reconciliation/effects.js +1 -0
- package/dist/core/reconciliation/effects.js.map +1 -1
- package/dist/core/reconciliation/errors/ReactError.d.ts.map +1 -1
- package/dist/core/reconciliation/errors/ReactError.js +3 -0
- package/dist/core/reconciliation/errors/ReactError.js.map +1 -1
- package/dist/core/reconciliation/fibers.d.ts +12 -2
- package/dist/core/reconciliation/fibers.d.ts.map +1 -1
- package/dist/core/reconciliation/fibers.js +60 -1
- package/dist/core/reconciliation/fibers.js.map +1 -1
- package/dist/core/reconciliation/invalidateFiber.js +2 -2
- package/dist/core/reconciliation/invalidateFiber.js.map +1 -1
- package/dist/core/reconciliation/mount.d.ts.map +1 -1
- package/dist/core/reconciliation/mount.js +22 -0
- package/dist/core/reconciliation/mount.js.map +1 -1
- package/dist/core/reconciliation/postCommit.d.ts.map +1 -1
- package/dist/core/reconciliation/postCommit.js +1 -0
- package/dist/core/reconciliation/postCommit.js.map +1 -1
- package/dist/debug.d.ts +2 -0
- package/dist/debug.d.ts.map +1 -0
- package/dist/debug.js +2 -0
- package/dist/debug.js.map +1 -0
- package/dist/hooks/index.d.ts +3 -2
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/index.js +3 -2
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/useEffect.d.ts +1 -0
- package/dist/hooks/useEffect.d.ts.map +1 -1
- package/dist/hooks/useEffect.js +2 -0
- package/dist/hooks/useEffect.js.map +1 -1
- package/dist/hooks/useId.js +1 -1
- package/dist/hooks/useId.js.map +1 -1
- package/dist/hooks/useRef.js +1 -1
- package/dist/hooks/useRef.js.map +1 -1
- package/dist/index.d.ts +48 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +28 -1
- package/dist/index.js.map +1 -1
- package/dist/types/app.d.ts +9 -0
- package/dist/types/app.d.ts.map +1 -1
- package/dist/types/component.d.ts +2 -0
- package/dist/types/component.d.ts.map +1 -1
- package/package.json +14 -1
package/dist/index.d.ts
CHANGED
|
@@ -12,4 +12,52 @@ export { Children } from './core/Children';
|
|
|
12
12
|
export declare function memo<T>(Comp: T, isEq?: unknown): T;
|
|
13
13
|
/** <Fragment/> */
|
|
14
14
|
export { FRAGMENT_TAG as Fragment } from './core/reconciliation/fibers';
|
|
15
|
+
export declare const version = "19.0.0";
|
|
16
|
+
export declare const unstable_batchedUpdates: (fn: () => void) => void;
|
|
17
|
+
import * as typesE from './types';
|
|
18
|
+
import * as hooksE from './hooks/index';
|
|
19
|
+
import * as classComponentE from './core/classComponent';
|
|
20
|
+
declare const _default: {
|
|
21
|
+
useCallback: typeof hooksE.useCallback;
|
|
22
|
+
createContext: <T>(defaultValue: T) => typesE.ReactContext<T>;
|
|
23
|
+
useContext: <T>(ctx: typesE.ReactContext<T>) => T;
|
|
24
|
+
useEffect: (fn: typesE.EffectHandler, deps?: unknown[] | undefined) => void;
|
|
25
|
+
useLayoutEffect: (fn: typesE.EffectHandler, deps?: unknown[] | undefined) => void;
|
|
26
|
+
useInsertionEffect: (fn: typesE.EffectHandler, deps?: unknown[] | undefined) => void;
|
|
27
|
+
useStableCallback: typeof hooksE.useStableCallback;
|
|
28
|
+
useId: typeof hooksE.useId;
|
|
29
|
+
useMemo: typeof hooksE.useMemo;
|
|
30
|
+
useRef: typeof hooksE.useRef;
|
|
31
|
+
forwardRef: <Props extends typesE.UnknownProps, R>(Component: (props: Props, ref?: typesE.Ref<R> | undefined) => typesE.JsxElement) => typesE.ReactComponent<Props & {
|
|
32
|
+
ref?: typesE.Ref<R> | undefined;
|
|
33
|
+
}>;
|
|
34
|
+
useImperativeHandle: <T>(ref: typesE.Ref<T> | undefined, factory: () => T, deps?: unknown[] | undefined) => void;
|
|
35
|
+
useState: <T>(initValue: T | (() => T) | (() => T)) => [T, typesE.StateSetter<T>];
|
|
36
|
+
useError: typeof hooksE.useError;
|
|
37
|
+
useReducer: typeof hooksE.useReducer;
|
|
38
|
+
isComponentClass: (value: unknown) => value is classComponentE.ComponentClass<typesE.UnknownProps, typesE.UnknownProps>;
|
|
39
|
+
Component: typeof classComponentE.Component;
|
|
40
|
+
convertClassComponentToFC: <Props extends typesE.UnknownProps, State extends typesE.UnknownProps = typesE.UnknownProps>(Component: classComponentE.ComponentClass<Props, State>) => typesE.ReactComponent<Props>;
|
|
41
|
+
containerSym: typeof typesE.containerSym;
|
|
42
|
+
createRoot(root: HTMLElement, options?: typesE.AppOptions | undefined): typesE.AppRoot;
|
|
43
|
+
createElementNew(type: classComponentE.ComponentClass | HTMLElement | typesE.ElementType | typesE.ReactContextProvider, propsRaw: Record<PropertyKey, unknown>, key: typesE.ReactKey | null | undefined, _isStaticChildren?: boolean | undefined, source?: typesE.JsxSource | null, _self?: unknown): typesE.ElementNode;
|
|
44
|
+
createPortal(children: typesE.JsxElement, domNode: HTMLElement, key?: string | undefined): typesE.ElementNode;
|
|
45
|
+
createElement(type: HTMLElement | typesE.ElementType | typesE.ReactContextProvider, propsRaw: Record<PropertyKey, unknown>, ...children: typesE.JsxElement[]): typesE.ElementNode;
|
|
46
|
+
cloneElement: (element: typesE.ElementNode, props?: typesE.UnknownProps | undefined, ...children: typesE.JsxElement[]) => typesE.ElementNode;
|
|
47
|
+
startTransition: (fn: () => void) => void;
|
|
48
|
+
flushSync: (fn: () => void) => void;
|
|
49
|
+
Suspense: () => never;
|
|
50
|
+
isValidElement: (value: unknown) => value is typesE.ElementNode;
|
|
51
|
+
Children: {
|
|
52
|
+
count: (children: typesE.JsxElement[]) => number;
|
|
53
|
+
only: (children: typesE.JsxElement) => asserts children is typesE.ElementNode | typesE.ScalarNode;
|
|
54
|
+
forEach: (children: typesE.JsxElement[], fn: (child: typesE.ElementNode | typesE.ScalarNode) => void, objThis?: unknown) => void;
|
|
55
|
+
map: <T>(chidlren: typesE.JsxElement[], fn: (child: typesE.ElementNode | typesE.ScalarNode) => T, objThis?: unknown) => T[];
|
|
56
|
+
toArray: (children: typesE.JsxElement[]) => (typesE.ElementNode | typesE.ScalarNode)[];
|
|
57
|
+
};
|
|
58
|
+
PureComponent: typeof classComponentE.Component;
|
|
59
|
+
version: string;
|
|
60
|
+
unstable_batchedUpdates: (fn: () => void) => void;
|
|
61
|
+
};
|
|
62
|
+
export default _default;
|
|
15
63
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC9E,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,wBAAgB,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,CAAC,CAMlD;AAED,kBAAkB;AAClB,OAAO,EAAE,YAAY,IAAI,QAAQ,EAAE,MAAM,8BAA8B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC9E,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,wBAAgB,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,CAAC,CAMlD;AAED,kBAAkB;AAClB,OAAO,EAAE,YAAY,IAAI,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAExE,eAAO,MAAM,OAAO,WAAW,CAAC;AAEhC,eAAO,MAAM,uBAAuB,0BAA2B,CAAC;AAEhE,OAAO,KAAK,MAAM,MAAM,SAAS,CAAC;AAElC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAGxC,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAMzD,wBAaE"}
|
package/dist/index.js
CHANGED
|
@@ -9,10 +9,37 @@ export { isValidElement } from './core/reconciliation/typeGuards';
|
|
|
9
9
|
export { Children } from './core/Children';
|
|
10
10
|
export function memo(Comp, isEq) {
|
|
11
11
|
if (isEq) {
|
|
12
|
-
|
|
12
|
+
console.warn(`Custom "isEqual" for memo is not supported`);
|
|
13
13
|
}
|
|
14
14
|
return Comp; // Components are already memoized by default.
|
|
15
15
|
}
|
|
16
16
|
/** <Fragment/> */
|
|
17
17
|
export { FRAGMENT_TAG as Fragment } from './core/reconciliation/fibers';
|
|
18
|
+
export const version = '19.0.0';
|
|
19
|
+
// It's the lib's behavior by default.
|
|
20
|
+
export const unstable_batchedUpdates = (fn) => fn();
|
|
21
|
+
import * as typesE from './types';
|
|
22
|
+
import * as reactTypesE from './types/react';
|
|
23
|
+
import * as hooksE from './hooks/index';
|
|
24
|
+
import * as createRootE from './core/createRoot';
|
|
25
|
+
import * as createElementE from './core/createElement';
|
|
26
|
+
import * as classComponentE from './core/classComponent';
|
|
27
|
+
import * as mocksE from './mocks';
|
|
28
|
+
import { isValidElement } from './core/reconciliation/typeGuards';
|
|
29
|
+
import { Children } from './core/Children';
|
|
30
|
+
// Some modular systems require this "default export".
|
|
31
|
+
export default {
|
|
32
|
+
...typesE,
|
|
33
|
+
...reactTypesE,
|
|
34
|
+
...hooksE,
|
|
35
|
+
...createRootE,
|
|
36
|
+
...createElementE,
|
|
37
|
+
...classComponentE,
|
|
38
|
+
...mocksE,
|
|
39
|
+
isValidElement,
|
|
40
|
+
Children,
|
|
41
|
+
PureComponent: classComponentE.Component,
|
|
42
|
+
version,
|
|
43
|
+
unstable_batchedUpdates,
|
|
44
|
+
};
|
|
18
45
|
//# 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":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC9E,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,MAAM,UAAU,IAAI,CAAI,IAAO,EAAE,IAAc,EAAK;IAClD,IAAI,IAAI,EAAE,CAAC;QACT,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,SAAS,EAAE,SAAS,IAAI,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC9E,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,MAAM,UAAU,IAAI,CAAI,IAAO,EAAE,IAAc,EAAK;IAClD,IAAI,IAAI,EAAE,CAAC;QACT,OAAO,CAAC,IAAI,CAAC,4CAA4C,CAAC,CAAC;IAC7D,CAAC;IAED,OAAO,IAAI,CAAC,CAAC,8CAA8C;AAA/C,CACb;AAED,kBAAkB;AAClB,OAAO,EAAE,YAAY,IAAI,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAExE,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC;AAChC,sCAAsC;AACtC,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EAAc,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC;AAEhE,OAAO,KAAK,MAAM,MAAM,SAAS,CAAC;AAClC,OAAO,KAAK,WAAW,MAAM,eAAe,CAAC;AAC7C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,WAAW,MAAM,mBAAmB,CAAC;AACjD,OAAO,KAAK,cAAc,MAAM,sBAAsB,CAAC;AACvD,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,MAAM,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,sDAAsD;AACtD,eAAe;IACb,GAAG,MAAM;IACT,GAAG,WAAW;IACd,GAAG,MAAM;IACT,GAAG,WAAW;IACd,GAAG,cAAc;IACjB,GAAG,eAAe;IAClB,GAAG,MAAM;IACT,cAAc;IACd,QAAQ;IACR,aAAa,EAAE,eAAe,CAAC,SAAS;IACxC,OAAO;IACP,uBAAuB;CACxB,CAAC"}
|
package/dist/types/app.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import type { PreactAdapter } from '../core/preact/types';
|
|
1
2
|
import type { FiberNode, JsxSource } from './fiber';
|
|
2
3
|
import type { EffectMode } from './hooks';
|
|
3
4
|
import type { Queue } from '../core/reconciliation/queue';
|
|
5
|
+
import type { AppDevTools } from '../core/devTools/types';
|
|
4
6
|
export type AppState =
|
|
5
7
|
/** Waiting for updates */
|
|
6
8
|
'idle'
|
|
@@ -72,6 +74,9 @@ export type App = {
|
|
|
72
74
|
* context values.
|
|
73
75
|
*/
|
|
74
76
|
tempContext: Map<number, unknown>;
|
|
77
|
+
/** HMR & React Dev Tools support. */
|
|
78
|
+
devTools: AppDevTools | null;
|
|
79
|
+
preact: PreactAdapter | null;
|
|
75
80
|
};
|
|
76
81
|
export type AppOptions = {
|
|
77
82
|
/**
|
|
@@ -85,6 +90,10 @@ export type AppOptions = {
|
|
|
85
90
|
* JSX into something that browser dev tools can properly handle.
|
|
86
91
|
*/
|
|
87
92
|
transformSource?: (source: JsxSource) => JsxSource;
|
|
93
|
+
/**
|
|
94
|
+
* Experimental Preact DevTools support. `undefined` by default.
|
|
95
|
+
*/
|
|
96
|
+
preactDevTools?: (app: App) => void;
|
|
88
97
|
};
|
|
89
98
|
export type AppRoot = {
|
|
90
99
|
render: (element: JSX.Element) => void;
|
package/dist/types/app.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/types/app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wCAAwC,CAAC;AAEpE,MAAM,MAAM,QAAQ;AAClB,0BAA0B;AACxB,MAAM;AACR;;;IAGI;GACF,WAAW;AACb;;;;;;;;GAQG;GACD,QAAQ;AACV;;;GAGG;GACD,QAAQ;AACV;;;GAGG;GACD,YAAY;AACd;;;;;GAKG;GACD,eAAe;AACjB;;;GAGG;GACD,SAAS;AACX;;GAEG;GACD,QAAQ,CAAC;AAEb,MAAM,MAAM,GAAG,GAAG;IAChB,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,iDAAiD;IACjD,IAAI,EAAE,SAAS,CAAC;IAChB,oDAAoD;IACpD,KAAK,EAAE,QAAQ,CAAC;IAChB,4CAA4C;IAC5C,OAAO,EAAE,MAAM,CACb,UAAU,EACV,KAAK,CAAC;QACJ,EAAE,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;QAC/B,KAAK,EAAE,SAAS,CAAC;QACjB,SAAS,EAAE,OAAO,CAAC;KACpB,CAAC,CACH,CAAC;IACF,0CAA0C;IAC1C,qBAAqB,EAAE,KAAK,CAAC;IAC7B,+CAA+C;IAC/C,QAAQ,EAAE,OAAO,CAAC;IAClB;gCAC4B;IAC5B,eAAe,CAAC,EAAE,CAAC,MAAM,EAAE,SAAS,KAAK,SAAS,CAAC;IACnD;;;;;OAKG;IACH,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/types/app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wCAAwC,CAAC;AACpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAC;AAEpE,MAAM,MAAM,QAAQ;AAClB,0BAA0B;AACxB,MAAM;AACR;;;IAGI;GACF,WAAW;AACb;;;;;;;;GAQG;GACD,QAAQ;AACV;;;GAGG;GACD,QAAQ;AACV;;;GAGG;GACD,YAAY;AACd;;;;;GAKG;GACD,eAAe;AACjB;;;GAGG;GACD,SAAS;AACX;;GAEG;GACD,QAAQ,CAAC;AAEb,MAAM,MAAM,GAAG,GAAG;IAChB,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,iDAAiD;IACjD,IAAI,EAAE,SAAS,CAAC;IAChB,oDAAoD;IACpD,KAAK,EAAE,QAAQ,CAAC;IAChB,4CAA4C;IAC5C,OAAO,EAAE,MAAM,CACb,UAAU,EACV,KAAK,CAAC;QACJ,EAAE,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;QAC/B,KAAK,EAAE,SAAS,CAAC;QACjB,SAAS,EAAE,OAAO,CAAC;KACpB,CAAC,CACH,CAAC;IACF,0CAA0C;IAC1C,qBAAqB,EAAE,KAAK,CAAC;IAC7B,+CAA+C;IAC/C,QAAQ,EAAE,OAAO,CAAC;IAClB;gCAC4B;IAC5B,eAAe,CAAC,EAAE,CAAC,MAAM,EAAE,SAAS,KAAK,SAAS,CAAC;IACnD;;;;;OAKG;IACH,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAClC,qCAAqC;IACrC,QAAQ,EAAE,WAAW,GAAG,IAAI,CAAC;IAC7B,MAAM,EAAE,aAAa,GAAG,IAAI,CAAC;CAC9B,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG;IACvB;;;QAGI;IACJ,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;OAIG;IACH,eAAe,CAAC,EAAE,CAAC,MAAM,EAAE,SAAS,KAAK,SAAS,CAAC;IACnD;;OAEG;IACH,cAAc,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAC;CACrC,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG;IACpB,MAAM,EAAE,CAAC,OAAO,EAAE,GAAG,CAAC,OAAO,KAAK,IAAI,CAAC;IACvC,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC"}
|
|
@@ -8,6 +8,8 @@ export type ComponentState = {
|
|
|
8
8
|
actions: Action[];
|
|
9
9
|
/** True when a component contains at least one useError handler. */
|
|
10
10
|
isErrorBoundary: boolean;
|
|
11
|
+
/** Is `true` when HMR marks this node to be remounted. */
|
|
12
|
+
remount: boolean;
|
|
11
13
|
};
|
|
12
14
|
export type ReactComponent<TProps extends UnknownProps = UnknownProps> = {
|
|
13
15
|
(props: TProps & ElementCommonAttrs): JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/types/component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,KAAK,EAAE,kBAAkB,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AAC/D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,EAAE,SAAS,GAAG,IAAI,CAA4B;IACnD;iBACa;IACb,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,oEAAoE;IACpE,eAAe,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/types/component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,KAAK,EAAE,kBAAkB,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AAC/D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC,MAAM,MAAM,cAAc,GAAG;IAC3B,KAAK,EAAE,SAAS,GAAG,IAAI,CAA4B;IACnD;iBACa;IACb,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,oEAAoE;IACpE,eAAe,EAAE,OAAO,CAAC;IACzB,0DAA0D;IAC1D,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,cAAc,CAAC,MAAM,SAAS,YAAY,GAAG,YAAY,IAAI;IACvE,CAAC,KAAK,EAAE,MAAM,GAAG,kBAAkB,GAAG,GAAG,CAAC,OAAO,CAAC;IAClD,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,iBAAiB,CAAC,MAAM,SAAS,YAAY,GAAG,YAAY,IACtE,MAAM,GAAG;IAAE,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;CAAE,CAAC;AAEtC,MAAM,MAAM,0BAA0B,CACpC,MAAM,SAAS,YAAY,GAAG,YAAY,IACxC,cAAc,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC,CAAC;AAE9C,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,MAAM,KAAK,KAAK,GAAG,CAAC,OAAO,GACzE,KAAK,GACL,KAAK,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faiwer/react",
|
|
3
|
-
"version": "19.0.
|
|
3
|
+
"version": "19.0.3",
|
|
4
4
|
"description": "A hobby project. A naive and simplified React implementation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -24,6 +24,15 @@
|
|
|
24
24
|
"dist/**/*",
|
|
25
25
|
"README.md"
|
|
26
26
|
],
|
|
27
|
+
"typesVersions": {
|
|
28
|
+
"*": {
|
|
29
|
+
"debug": ["./dist/debug.d.ts"],
|
|
30
|
+
"jsx-runtime": ["./dist/jsx-runtime.d.ts"],
|
|
31
|
+
"jsx-dev-runtime": ["./dist/jsx-dev-runtime.d.ts"],
|
|
32
|
+
"jsx": ["./dist/jsx.d.ts"]
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"sideEffects": ["dist/core/reconciliation/app.js"],
|
|
27
36
|
"exports": {
|
|
28
37
|
".": {
|
|
29
38
|
"types": "./dist/index.d.ts",
|
|
@@ -43,6 +52,10 @@
|
|
|
43
52
|
},
|
|
44
53
|
"./jsx": {
|
|
45
54
|
"types": "./dist/jsx.d.ts"
|
|
55
|
+
},
|
|
56
|
+
"./debug": {
|
|
57
|
+
"types": "./dist/debug.d.ts",
|
|
58
|
+
"default": "./dist/debug.js"
|
|
46
59
|
}
|
|
47
60
|
},
|
|
48
61
|
"scripts": {
|