@@ -64,15 +64,7 @@ export class NgtStore extends NgtRxStore<NgtState> {
6464 const fov = ( camera . fov * Math . PI ) / 180 ; // convert vertical fov to radians
6565 const h = 2 * Math . tan ( fov / 2 ) * distance ; // visible height
6666 const w = h * aspect ;
67- return {
68- width : w ,
69- height : h ,
70- top,
71- left,
72- factor : width / w ,
73- distance,
74- aspect,
75- } ;
67+ return { width : w , height : h , top, left, factor : width / w , distance, aspect } ;
7668 } ;
7769
7870 const pointer = new THREE . Vector2 ( ) ;
@@ -287,9 +279,8 @@ export class NgtStore extends NgtRxStore<NgtState> {
287279 camera . updateProjectionMatrix ( ) ;
288280 }
289281
290- if ( ! is . instance ( camera ) ) {
291- camera = prepare ( camera , { store : this } ) ;
292- }
282+ if ( ! is . instance ( camera ) ) camera = prepare ( camera , { store : this } ) ;
283+
293284 stateToUpdate . camera = camera ;
294285 }
295286
@@ -370,9 +361,7 @@ export class NgtStore extends NgtRxStore<NgtState> {
370361 }
371362
372363 // Store events internally
373- if ( events && ! state . events . handlers ) {
374- stateToUpdate . events = events ( this ) ;
375- }
364+ if ( events && ! state . events . handlers ) stateToUpdate . events = events ( this ) ;
376365
377366 // Check performance
378367 if ( performance && ! is . equ ( performance , state . performance , shallowLoose ) ) {
@@ -390,9 +379,7 @@ export class NgtStore extends NgtRxStore<NgtState> {
390379 // Check frameloop
391380 if ( state . frameloop !== frameloop ) state . setFrameloop ( frameloop ) ;
392381
393- if ( ! this . get ( 'ready' ) ) {
394- this . set ( { ready : true } ) ;
395- }
382+ if ( ! this . get ( 'ready' ) ) this . set ( { ready : true } ) ;
396383
397384 this . invalidate ( ) ;
398385 }
0 commit comments