Skip to content

Commit b9a6aa6

Browse files
committed
v0.2.1
1 parent a33fd43 commit b9a6aa6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-adopt",
3-
"version": "0.2.0",
3+
"version": "0.2.1",
44
"main": "dist/index.js",
55
"umd:main": "dist/index.umd.js",
66
"module": "dist/index.m.js",

src/index.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ export type RPC<RenderProps, Props = {}> = ComponentType<
2020
}
2121
>
2222

23-
const isFn = (val: any): boolean => Boolean(val) && typeof val === 'function'
24-
2523
function omit<R = object>(obj: any, omitProps: string[]): R {
2624
const newObj = keys(obj)
2725
.filter((key: string): boolean => omitProps.indexOf(key) === -1)
@@ -33,6 +31,8 @@ function omit<R = object>(obj: any, omitProps: string[]): R {
3331
return newObj as R
3432
}
3533

34+
const isFn = (val: any): boolean => Boolean(val) && typeof val === 'function'
35+
3636
const isValidRenderProp = (prop: ReactNode | ChildrenFn<any>): boolean =>
3737
React.isValidElement(prop) || isFn(prop)
3838

0 commit comments

Comments
 (0)