What are the advantages of just-in-time compilation versus ahead-of-time compilation?

前端 未结 9 2275
挽巷
挽巷 2020-12-02 05:56

I\'ve been thinking about it lately, and it seems to me that most advantages given to JIT compilation should more or less be attributed to the intermediate

9条回答
  •  再見小時候
    2020-12-02 06:22

    The difference between platform-browser-dynamic and platform-browser is the way your angular app will be compiled. Using the dynamic platform makes angular sending the Just-in-Time compiler to the front-end as well as your application. Which means your application is being compiled on client-side. On the other hand, using platform-browser leads to an Ahead-of-Time pre-compiled version of your application being sent to the browser. Which usually means a significantly smaller package being sent to the browser. The angular2-documentation for bootstrapping at https://angular.io/docs/ts/latest/guide/ngmodule.html#!#bootstrap explains it in more detail.

提交回复
热议问题