What are Access Modifiers in TypeScript ?

Опубликовано: 31 Январь 2021
на канале: TechnoFunnel
50
1

Like others programming languages, TypeScript supports access modifiers at the class level. TypeScript supports three access modifiers - public, private, and protected.

Public - By default, members (properties and methods) of TypeScript class are public - so you don’t need to prefix members with the public keyword. Public members are accessible everywhere without restrictions

Private - A private member cannot be accessed outside of its containing class. Private members can be accessed only within the class.

Protected - A protected member cannot be accessed outside of its containing class. Protected members can be accessed only within the class and by the instance of its sub/child class.

Our Website: www.technofunnel.com
Medium Channel:   / mayank-gupta-6-88  

Connect me on LinkedIn:   / mayank-gu.  .

LinkedIn Company Details:   / 7159.  .

Facebook Page:   / learnjavascr.  .


About TechnoFunnel:
We provide Corporate and Professional training on the latest Technologies. Trainings bring you in par with Industrial Standards. We help you to prepare for interviews in Different Domains. Mock Interview Questions and Interviews. Confused about your career? We offer you professionals to help shape your career. Connect us for the same. We are focussed towards the bringing the Industrial Standard Software Programing Courses

#javascript #typescript #frontend #programming #typescriptbasics