Câu hỏi phỏng vấn Angular
Câu hỏi

Do I need to bootst...

Câu trả lời

No, you do not need to bootstrap custom elements. Custom elements, which are a key feature of the Web Components standard, bootstrap automatically when they are added to the DOM and are destroyed when removed from the DOM. Once a custom element is added to the DOM, it behaves like any other HTML element without requiring any special knowledge of Angular or additional bootstrapping[1].

However, when working with Angular Elements, which are Angular components packaged as custom elements, there is a specific build flow for creating them. In this context, the term "bootstrap" is used differently. For Angular Element creation, the bootstrap module is ElementModule instead of AppModule. This is because ElementModule is responsible for registering the component as a custom element in the browser's CustomElementRegistry. The ElementModule needs to implement the DoBootstrap interface, and within it, the ngDoBootstrap() method is used for the ...

senior

senior

Gợi ý câu hỏi phỏng vấn

expert

Just-in-Time (JIT) vs Ahead-of-Time (AOT) compilation. Explain the difference

middle

What is Bazel?

senior

Are there any pros/cons (especially performance-wise) in using local storage to replace cookie
functionality?

Bình luận

Chưa có bình luận nào

Chưa có bình luận nào