AoT limitations

However, AoT is not perfect. The main limitation is that AoT, due to the way it compiles the raw code, cannot be used with common code patterns, for example, default exports from modules, template literals for templates, and functions in providers, routes, or declarations. Currently, we do not have a complete list of "AoT Do's and Don'ts" and the Angular team has not released anything regarding this issue. Rangle made its own list here and also provides a sandbox for testing features with AoT.

Another problem with AoT is that when the application reaches certain complexity, the AoT bundle compared to JiT bundle can actually takes up more space. As an trade-off of having a simpler logic for browser (therefore faster rendering speed), the code generated by AoT is actually more verbose compared to "dynamic" JiT.

results matching ""

    No results matching ""