Angular Component Interaction - @ViewChild | Pass Data Between Component | CodeWithSrini

Share this & earn $10
CodeWithSrini
Published at : 29 Dec 2020
1165 views
26
2

With @ViewChild, we can access information from child component esp values from our child component.

A ViewChild has two params, a selector and an option termed as opts which is an object.

Selector can be a template ref or a component, so in this case it’s DrugComponent.

And in the option we have to set static as false.

In the newer release of Angular presumably Angular 9 the default static is set to false.
javascripttypescriptangular lesson

Day in the Life of a Facebook Software Engineer.

Day in the Life of a Facebook Software Engineer.

How to earning The shoppers || The shoppers app kaise use kare || The shoppers app unlimited trick

How to earning The shoppers || The shoppers app kaise use kare || The shoppers app unlimited trick

The Columbus Gay Men’s Chorus Presents WJOY: A Virtual Concert Experience

The Columbus Gay Men’s Chorus Presents WJOY: A Virtual Concert Experience

John and Julie Gottman: Eight Dates: Essential Conversations for a Lifetime of Love (03/13/19)

John and Julie Gottman: Eight Dates: Essential Conversations for a Lifetime of Love (03/13/19)

New Popularity Redeem Code Finally| How to Get Winter Dance Santa Popularity  | PUBG MOBILE

New Popularity Redeem Code Finally| How to Get Winter Dance Santa Popularity | PUBG MOBILE

Handheld weekly remote controller - Advanced features

Handheld weekly remote controller - Advanced features

Special Bulletin (1983)

Special Bulletin (1983)

57 Things We Don't Buy Anymore | Family Minimalism

57 Things We Don't Buy Anymore | Family Minimalism

Weight Loss 6-8 Kg in 30 Days - Aerobic Dance Workout Everyday for The Best Body Shape | Eva Fitness

Weight Loss 6-8 Kg in 30 Days - Aerobic Dance Workout Everyday for The Best Body Shape | Eva Fitness

In Different Ways (Jon Lajoie)

In Different Ways (Jon Lajoie)

Come Across

Come Across

「Chilly - NIKI (lyrics)🌩」

「Chilly - NIKI (lyrics)🌩」

Noel Gallagher’s High Flying Birds - Do The Damage

Noel Gallagher’s High Flying Birds - Do The Damage

A Bit More Yorkshire Brass #38

A Bit More Yorkshire Brass #38

A2 Flyers speaking test – Michaela | Cambridge English

A2 Flyers speaking test – Michaela | Cambridge English

APLICACIONES PARA ARQUITECTOS - MI TOP 3

APLICACIONES PARA ARQUITECTOS - MI TOP 3

Huanyang VFD wireless control

Huanyang VFD wireless control

SNOWMAN (lyrics) SIA

SNOWMAN (lyrics) SIA

Deep Sleep Relaxing Music for Relaxed Souls,Natural Sound,Calm Sound, Soothing birds.

Deep Sleep Relaxing Music for Relaxed Souls,Natural Sound,Calm Sound, Soothing birds.

How to Make a Faux Fur Pillow

How to Make a Faux Fur Pillow

Bea Miller, 6LACK - it's not u it's me

Bea Miller, 6LACK - it's not u it's me

MEJT stock market forecast 21 DEC 2020

MEJT stock market forecast 21 DEC 2020

easy methods to live more frugally

easy methods to live more frugally

To Twelve – Horses

To Twelve – Horses

Cussly's Politeness + Many More ChuChu TV Good Habits Bedtime Stories For Kids

Cussly's Politeness + Many More ChuChu TV Good Habits Bedtime Stories For Kids

Fatherless Homes To Prove a Point (Analysis) Crys Speaks

Fatherless Homes To Prove a Point (Analysis) Crys Speaks

PREMIERE: AARYON - Unpleasant (Original Mix) [RUKUS]

PREMIERE: AARYON - Unpleasant (Original Mix) [RUKUS]

Mike Brown: Dustin Poirier to test Conor McGregor's cardio | UFC 257 interview

Mike Brown: Dustin Poirier to test Conor McGregor's cardio | UFC 257 interview

turning  into WAIWAI vacuum, see what we did when there's a chaos outside !

turning into WAIWAI vacuum, see what we did when there's a chaos outside !

Billy Ray Cyrus - Achy Breaky Heart (Official Music Video)

Billy Ray Cyrus - Achy Breaky Heart (Official Music Video)

Scientifically Plausible Aliens

Scientifically Plausible Aliens

Learn English Conversation - Oxford English Daily Conversation Part 1

Learn English Conversation - Oxford English Daily Conversation Part 1

Sometimes You're A Caterpillar

Sometimes You're A Caterpillar

PISCES! "OMG IT MAY BLOW YOUR MIND HOW MUCH YOU ALREADY KNEW THIS..." 2021 TAROT CARD READING

PISCES! "OMG IT MAY BLOW YOUR MIND HOW MUCH YOU ALREADY KNEW THIS..." 2021 TAROT CARD READING

Comparison: Computer Viruses

Comparison: Computer Viruses

How to edit certificate and documents in Android phone

How to edit certificate and documents in Android phone

Laptop Displays - CompTIA A+ 220-1001 - 1.2

Laptop Displays - CompTIA A+ 220-1001 - 1.2

Relaxing and pleasant music You will not regret hearing it

Relaxing and pleasant music You will not regret hearing it

How to create a Purchase Order in SAP - SAP MM basic Video

How to create a Purchase Order in SAP - SAP MM basic Video

NEW!! Small Toy Hauler 17BLSE Freedom Express

NEW!! Small Toy Hauler 17BLSE Freedom Express

The Real Cost of Outside Investment

The Real Cost of Outside Investment

Make Better Today - Luis Sierra Campos | Presented by TakePart + Lenovo

Make Better Today - Luis Sierra Campos | Presented by TakePart + Lenovo

i completed this impossible bottle flip stack challenge and this happened

i completed this impossible bottle flip stack challenge and this happened

Vlad and Niki Chocolate Challenge | Funny stories for kids

Vlad and Niki Chocolate Challenge | Funny stories for kids

Describing Animals  with Simple Present Tense

Describing Animals with Simple Present Tense

Suffering from Fungal Infection, Ringworms? WATCH THIS!

Suffering from Fungal Infection, Ringworms? WATCH THIS!

John Frusciante - Become

John Frusciante - Become

THE EASIEST WAY TO TELL IF IT'S A WALKOUT OR BOARD!!! FIFA 21 Ultimate Team

THE EASIEST WAY TO TELL IF IT'S A WALKOUT OR BOARD!!! FIFA 21 Ultimate Team

SEEN  - Trịnh Thăng Bình (Lyrics Video)

SEEN - Trịnh Thăng Bình (Lyrics Video)