mirror of
https://github.com/johannesjo/super-productivity.git
synced 2026-01-22 18:30:09 +00:00
perf: add OnPush change detection to components
- Add OnPush to ConfigSoundFormComponent - Add OnPush to TaskViewCustomizerPanelComponent - Improves change detection performance for these components
This commit is contained in:
parent
49dc92d588
commit
4e235efb3f
2 changed files with 4 additions and 2 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { Component, Input, output } from '@angular/core';
|
||||
import { ChangeDetectionStrategy, Component, Input, output } from '@angular/core';
|
||||
import { FormControl, FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
||||
import { GlobalConfigSectionKey, SoundConfig } from '../global-config.model';
|
||||
import { ProjectCfgFormKey } from '../../project/project.model';
|
||||
|
|
@ -23,6 +23,7 @@ const sectionKey = 'sound';
|
|||
selector: 'config-sound-form',
|
||||
templateUrl: './config-sound-form.component.html',
|
||||
styleUrls: ['./config-sound-form.component.scss'],
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
imports: [
|
||||
CollapsibleComponent,
|
||||
FormsModule,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { Component } from '@angular/core';
|
||||
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
||||
import { OnInit } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { FormsModule } from '@angular/forms';
|
||||
|
|
@ -15,6 +15,7 @@ import { T } from 'src/app/t.const';
|
|||
selector: 'task-view-customizer-panel',
|
||||
templateUrl: './task-view-customizer-panel.component.html',
|
||||
styleUrls: ['./task-view-customizer-panel.component.scss'],
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
standalone: true,
|
||||
imports: [
|
||||
CommonModule,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue