Skip to content
Advertisement

Tag: angularjs

How to pass data from child to parent?

I need to pass one variable, that is inside my child component, to parent page. This variable that I am trying to pass, is the array result of Barcode Scanner. And I need to pass it to parent to send to API. childComponent.ts parentComponent.ts Answer Here is an example stackblitz project to test parent-child data transfer, using @Input() and @Output()mechanism

document.querySelector() is not applying style

Could someone point my mistake here ? I’m trying to modify the class the property but am actually getting TypeError: Cannot read property ‘style’ of null in my Angular.js 1.x application. But when try in fiddle, I couldn’t see the error but also style is not applied. Thanks every one Answer Please see the following working snippet. Also keep in

Advertisement