Код: Выделить всё
@Component({ ... })
export class SomeComponent {
@Input() test = null;
ngOnInit() {
this.test = 'qwerty';
}
...
Код: Выделить всё
@Component({ ... })
export class SomeComponent {
test = input(null);
ngOnInit() {
this.test.set('qwerty'); //
Подробнее здесь: [url]https://stackoverflow.com/questions/79451340/how-do-i-refactor-an-input-which-is-being-updated-directly-which-is-not-poss[/url]
Мобильная версия