M Mr. Dubey • 100.28K Points Coach Bookmark Embed Report View In MB-Short Q. How do you declare a service to be injectable throughout the app? (A) Add @Injectable({ providedIn: 'root' }) (B) Declare it in app.module.ts providers array only (C) Declare it in every component providers array (D) Use @Component decorator Correct Answer - Option(A) Views: 13 Filed under category Angular Share
Discusssion
Login to discuss.