From 3e55c9a7b960d7c9596cdc988fb9a7bf33a8c4f9 Mon Sep 17 00:00:00 2001 From: Alexey Lyakhov Date: Sun, 22 Nov 2020 23:59:00 +0700 Subject: [PATCH] fix reconsciler issue, fix couple ts issues (#827) --- src/renderer.tsx | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/renderer.tsx b/src/renderer.tsx index 529f9808ce..8556aa369d 100644 --- a/src/renderer.tsx +++ b/src/renderer.tsx @@ -1,6 +1,7 @@ import * as THREE from 'three' import * as React from 'react' -import * as Reconciler from 'react-reconciler' +// @ts-ignore +import Reconciler from 'react-reconciler' // @ts-ignore //import Reconciler from 'react-reconciler/cjs/react-reconciler.production.min' import { unstable_now as now, unstable_IdlePriority as idlePriority, unstable_runWithPriority as run } from 'scheduler' @@ -480,21 +481,18 @@ function switchInstance(instance: any, type: string, newProps: any, fiber: Recon // TimeoutHandle, // NoTimeout // > -const Renderer = Reconciler({ +const Renderer = Reconciler({ now, createInstance, removeChild, appendChild, insertBefore, - // @ts-ignore warnsIfNotActing: true, supportsMutation: true, isPrimaryRenderer: false, scheduleTimeout: is.fun(setTimeout) ? setTimeout : undefined, cancelTimeout: is.fun(clearTimeout) ? clearTimeout : undefined, - // @ts-ignore setTimeout: is.fun(setTimeout) ? setTimeout : undefined, - // @ts-ignore clearTimeout: is.fun(clearTimeout) ? clearTimeout : undefined, noTimeout: -1, appendInitialChild: appendChild, @@ -556,7 +554,7 @@ const Renderer = Reconciler