Angular JS MCQs with answers Page - 3

Here, you will find a collection of MCQ questions on Angular JS. Go through these questions to enhance your preparation for upcoming examinations and interviews.

To check the correct answer, simply click the View Answer button provided for each question.

Have your own questions to contribute? Click the button below to share your MCQs with others!

+ Add Question

A

Admin • 831.35K Points
Coach

Q. Which pipe is used to format currency values in Angular?

  • (A) number
  • (B) currency
  • (C) money
  • (D) cash

A

Admin • 831.35K Points
Coach

Q. What is the role of HttpClient in Angular?

  • (A) To create components
  • (B) To route between pages
  • (C) To make HTTP requests
  • (D) To handle reactive forms

A

Admin • 831.35K Points
Coach

Q. Which directive is used to repeat a portion of HTML?

  • (A) *ngIf
  • (B) *ngSwitch
  • (C) *ngFor
  • (D) *ngRepeat

A

Admin • 831.35K Points
Coach

Q. Which function is used to unsubscribe from an observable manually?

  • (A) close()
  • (B) unsubscribe()
  • (C) stop()
  • (D) detach()

A

Admin • 831.35K Points
Coach

Q. What is the use of @Injectable decorator in Angular?

  • (A) To define a pipe
  • (B) To define a component
  • (C) To define a service for dependency injection
  • (D) To define a module

A

Admin • 831.35K Points
Coach

Q. Which lifecycle hook is called before Angular destroys the component?

  • (A) ngOnDestroy
  • (B) ngAfterViewInit
  • (C) ngDoCheck
  • (D) ngAfterContentInit

A

Admin • 831.35K Points
Coach

Q. Which interface is implemented to use ngOnInit?

  • (A) OnChanges
  • (B) OnDestroy
  • (C) OnInit
  • (D) DoCheck

A

Admin • 831.35K Points
Coach

Q. Which Angular concept allows sharing data between unrelated components?

  • (A) Child components
  • (B) Parent components
  • (C) Services
  • (D) Pipes

A

Admin • 831.35K Points
Coach

Q. What does 'ng' stand for in Angular CLI commands?

  • (A) Next Generation
  • (B) Angular
  • (C) Node Generator
  • (D) New Generator

A

Admin • 831.35K Points
Coach

Q. Which of the following is NOT a valid Angular directive?

  • (A) *ngIf
  • (B) *ngFor
  • (C) *ngSwitch
  • (D) *ngRepeat