File tree Expand file tree Collapse file tree 3 files changed +44
-45
lines changed
Expand file tree Collapse file tree 3 files changed +44
-45
lines changed Original file line number Diff line number Diff line change 1919 "gzipped" : 1999
2020 },
2121 "dist/web.js" : {
22- "bundled" : 63059 ,
23- "minified" : 29978 ,
24- "gzipped" : 10898 ,
22+ "bundled" : 63153 ,
23+ "minified" : 30004 ,
24+ "gzipped" : 10904 ,
2525 "treeshaked" : {
2626 "rollup" : {
2727 "code" : 11455 ,
3838 "gzipped" : 11641
3939 },
4040 "dist/native.js" : {
41- "bundled" : 60184 ,
42- "minified" : 28050 ,
43- "gzipped" : 9921 ,
41+ "bundled" : 60278 ,
42+ "minified" : 28076 ,
43+ "gzipped" : 9927 ,
4444 "treeshaked" : {
4545 "rollup" : {
4646 "code" : 8256 ,
5252 }
5353 },
5454 "dist/universal.js" : {
55- "bundled" : 47621 ,
56- "minified" : 21340 ,
57- "gzipped" : 7118 ,
55+ "bundled" : 47715 ,
56+ "minified" : 21366 ,
57+ "gzipped" : 7125 ,
5858 "treeshaked" : {
5959 "rollup" : {
6060 "code" : 1235 ,
6666 }
6767 },
6868 "dist/konva.js" : {
69- "bundled" : 58681 ,
70- "minified" : 27202 ,
71- "gzipped" : 9829 ,
69+ "bundled" : 58775 ,
70+ "minified" : 27228 ,
71+ "gzipped" : 9834 ,
7272 "treeshaked" : {
7373 "rollup" : {
7474 "code" : 8974 ,
157157 "gzipped" : 9928
158158 },
159159 "dist/web.cjs.js" : {
160- "bundled" : 71464 ,
161- "minified" : 33758 ,
162- "gzipped" : 11481
160+ "bundled" : 71558 ,
161+ "minified" : 33790 ,
162+ "gzipped" : 11484
163163 },
164164 "dist/native.cjs.js" : {
165- "bundled" : 69070 ,
166- "minified" : 32016 ,
167- "gzipped" : 10476
165+ "bundled" : 69164 ,
166+ "minified" : 32048 ,
167+ "gzipped" : 10484
168168 },
169169 "dist/renderprops.cjs.js" : {
170170 "bundled" : 77632 ,
192192 "gzipped" : 10452
193193 },
194194 "dist/universal.cjs.js" : {
195- "bundled" : 55697 ,
196- "minified" : 24987 ,
197- "gzipped" : 7681
195+ "bundled" : 55791 ,
196+ "minified" : 25019 ,
197+ "gzipped" : 7687
198198 },
199199 "dist/test.js" : {
200200 "bundled" : 32365 ,
216216 "gzipped" : 5405
217217 },
218218 "dist/konva.cjs.js" : {
219- "bundled" : 66798 ,
220- "minified" : 30880 ,
221- "gzipped" : 10381
219+ "bundled" : 66892 ,
220+ "minified" : 30912 ,
221+ "gzipped" : 10387
222222 },
223223 "dist/three.js" : {
224- "bundled" : 58622 ,
225- "minified" : 27013 ,
226- "gzipped" : 9703 ,
224+ "bundled" : 58973 ,
225+ "minified" : 27132 ,
226+ "gzipped" : 9745 ,
227227 "treeshaked" : {
228228 "rollup" : {
229- "code" : 8805 ,
230- "import_statements" : 313
229+ "code" : 10339 ,
230+ "import_statements" : 344
231231 },
232232 "webpack" : {
233- "code" : 10009
233+ "code" : 11539
234234 }
235235 }
236236 },
237237 "dist/three.cjs.js" : {
238- "bundled" : 66753 ,
239- "minified" : 30697 ,
240- "gzipped" : 10253
238+ "bundled" : 67146 ,
239+ "minified" : 30864 ,
240+ "gzipped" : 10293
241241 }
242242}
Original file line number Diff line number Diff line change @@ -130,24 +130,23 @@ const update = () => {
130130 if ( controllers . size ) {
131131 if ( manualFrameloop ) manualFrameloop ( )
132132 else requestFrame ( update )
133- } else active = false
133+ } else {
134+ active = false
135+ }
134136 return active
135137}
136138
137139const start = ( controller : Controller ) => {
138- if ( ! controllers . has ( controller ) ) {
139- controllers . add ( controller )
140- if ( ! active ) {
141- if ( manualFrameloop ) requestFrame ( manualFrameloop )
142- else requestFrame ( update )
143- }
140+ if ( ! controllers . has ( controller ) ) controllers . add ( controller )
141+ if ( ! active ) {
144142 active = true
143+ if ( manualFrameloop ) requestFrame ( manualFrameloop )
144+ else requestFrame ( update )
145145 }
146146}
147147
148148const stop = ( controller : Controller ) => {
149- if ( controllers . has ( controller ) )
150- controllers . delete ( controller )
149+ if ( controllers . has ( controller ) ) controllers . delete ( controller )
151150}
152151
153152export { start , stop , update }
Original file line number Diff line number Diff line change 11import * as THREE from 'three'
2- import { applyProps , addEffect , invalidate } from 'react-three-fiber'
2+ import { invalidate , applyProps , addEffect } from 'react-three-fiber'
33import { interpolate } from '../../interpolate'
44import animated from '../../animated/createAnimatedComponent'
55import * as Globals from '../../animated/Globals'
@@ -20,8 +20,8 @@ const extendedAnimated = apply(THREE)
2020if ( addEffect ) {
2121 // Add the update function as a global effect to react-three-fibers update loop
2222 addEffect ( update )
23- // Hook up the invalidate function to react-springs update-loop
24- Globals . injectManualFrameloop ( invalidate )
23+ // We don't really need to invalidate, since react-spring is most likely causing invalidation through applyProps
24+ Globals . injectManualFrameloop ( ( ) => invalidate ( ) )
2525}
2626
2727// Set default native-element
You can’t perform that action at this time.
0 commit comments