Home / CSE MCQs / Angular 4 ::

CSE MCQs :: Angular 4

  1. How does Angular 4 improved error handling, when an error is caused by something in a template?
  2. A.
    By enabling TypeScript's StrictNullChecks
    B.
    By creating flattened versions of Angular modules
    C.
    By generating source maps in terms of original template
    D.
    None of the mentioned

  3. The . . . . . decorator allows us to define the pipe name that is globally available for use in any template in the across application.
  4. A.
    pipeName
    B.
    pipeDeco
    C.
    Pipe
    D.
    None

  5. Observables help you manage . . . . . . . . data.
  6. A.
    synchronous
    B.
    asynchronous
    C.
    Both asynchronous & synchronous
    D.
    None of above

  7. Where would you put it?
  8. A.
    In the Component
    B.
    In the Template
    C.
    In the Injectable decorator
    D.
    In the module

  9. How would you display a list of Employees on a webpage along with where they were in the list?
  10. A.
    Loop through and print the index
    B.
    Loop through and print the employees
    C.
    Loop through and print the index and the employee
    D.
    Pass both the index and the employee to a web service

  11. If you chain multiple pipes together, they are executed
  12. A.
    in parallel
    B.
    LIFO order
    C.
    in the order in which you specify them
    D.
    None of above

  13. We can subscribe to an observable using the . . . . . . . . The benefit of this is that Angular deals with your subscription during the lifecycle of a component. Angular will automatically subscribe and unsubscribe for you.
  14. A.
    sync pipe
    B.
    async var
    C.
    async pipe
    D.
    syn var

  15. The number pipe is location sensitive, which means that the same format argument will produce differently formatted results based on the . . . . . . .
  16. A.
    user's format setting
    B.
    user's currency setting
    C.
    user's locale setting
    D.
    All of above

  17. How would you retrieve a list of items from a server's URL?
  18. A.
    Create a URL transaction
    B.
    Use the HTTP get method
    C.
    Create a get SQL statement
    D.
    Use an HTTP package

  19. Which of the following is not built-in pipe in Angular?
  20. A.
    DatePipe
    B.
    CurrencyPipe
    C.
    DataPipe
    D.
    PercentPipe