The Wayback Machine - https://web.archive.org/web/20211020045626/https://github.com/angular/angular/pull/40127
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(compiler-cli): JIT compilation of component declarations #40127

Closed
wants to merge 3 commits into from

Conversation

@JoostK
Copy link
Member

@JoostK JoostK commented Dec 15, 2020

The ɵɵngDeclareComponent calls are designed to be translated to fully
AOT compiled code during a build transform, but in cases this is not
done it is still possible to compile the declaration object in the
browser using the JIT compiler. This commit adds a runtime
implementation of ɵɵngDeclareComponent which invokes the JIT compiler
using the declaration object, such that a compiled component definition
is made available to the Ivy runtime.

@ngbot ngbot bot added this to the Backlog milestone Dec 15, 2020
@google-cla google-cla bot added the cla: yes label Dec 15, 2020
@JoostK JoostK force-pushed the linker/components_jit branch from a551632 to 3a06049 Dec 15, 2020
@JoostK JoostK added this to In progress in ng-linker via automation Dec 15, 2020
@JoostK JoostK force-pushed the linker/components_jit branch 5 times, most recently from 557e067 to e685467 Dec 18, 2020
@google-cla
Copy link

@google-cla google-cla bot commented Dec 18, 2020

All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter.

We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only @googlebot I consent. in this pull request.

Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the cla label to yes (if enabled on your project).

ℹ️ Googlers: Go here for more info.

@google-cla google-cla bot added cla: no and removed cla: yes labels Dec 18, 2020
@JoostK JoostK force-pushed the linker/components_jit branch from e685467 to 74545fe Dec 23, 2020
@google-cla google-cla bot added cla: yes and removed cla: no labels Dec 23, 2020
@JoostK JoostK force-pushed the linker/components_jit branch from 74545fe to 1da1beb Dec 23, 2020
@JoostK JoostK marked this pull request as ready for review Dec 23, 2020
@pullapprove pullapprove bot requested review from atscott and gkalpak Dec 23, 2020
@JoostK JoostK requested review from petebacondarwin and removed request for atscott Dec 23, 2020
@pullapprove pullapprove bot requested a review from atscott Dec 23, 2020
@JoostK JoostK moved this from In progress to Review in progress in ng-linker Dec 23, 2020
Copy link
Member

@petebacondarwin petebacondarwin left a comment

Another marvellous PR @JoostK - just a couple of nits and bike-sheds.

packages/compiler/src/render3/view/compiler.ts Outdated Show resolved Hide resolved
packages/compiler/src/render3/partial/component.ts Outdated Show resolved Hide resolved
packages/compiler/src/render3/view/api.ts Outdated Show resolved Hide resolved
packages/compiler/src/jit_compiler_facade.ts Outdated Show resolved Hide resolved
packages/compiler/src/jit_compiler_facade.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@atscott atscott left a comment

reviewed-for: fw-core

@JoostK JoostK force-pushed the linker/components_jit branch from 1da1beb to 62f7981 Dec 28, 2020
Copy link
Member

@gkalpak gkalpak left a comment

Reviewed-for: dev-infra

@JoostK JoostK moved this from Review in progress to Reviewer approved in ng-linker Dec 28, 2020
Copy link
Member

@petebacondarwin petebacondarwin left a comment

L even better TM

JoostK added 3 commits Jan 5, 2021
The `render3` test targets are currently also executed for ViewEngine
builds, even though the `render3` infrastructure only concerns Ivy
infrastructure. This commit tags the test targets as ivy-only to disable
those tests for View Engine.
The `ɵɵngDeclareComponent` calls are designed to be translated to fully
AOT compiled code during a build transform, but in cases this is not
done it is still possible to compile the declaration object in the
browser using the JIT compiler. This commit adds a runtime
implementation of `ɵɵngDeclareComponent` which invokes the JIT compiler
using the declaration object, such that a compiled component definition
is made available to the Ivy runtime.
@JoostK JoostK force-pushed the linker/components_jit branch from 62f7981 to b5b2b9e Jan 5, 2021
josephperrott added a commit that referenced this issue Jan 6, 2021
The `ɵɵngDeclareComponent` calls are designed to be translated to fully
AOT compiled code during a build transform, but in cases this is not
done it is still possible to compile the declaration object in the
browser using the JIT compiler. This commit adds a runtime
implementation of `ɵɵngDeclareComponent` which invokes the JIT compiler
using the declaration object, such that a compiled component definition
is made available to the Ivy runtime.

PR Close #40127
ng-linker automation moved this from Reviewer approved to Done Jan 6, 2021
JoostK added a commit to JoostK/angular that referenced this issue Jan 7, 2021
…ction name

The "monitoring" workflow is has been failing since angular#40127 was merged,
due to a Saucelabs test failure in Internet Explorer 11. The issue is
with the test's expectation which does not account for Ivy instruction
invocations to use "anonymous" instead of the instruction's function
name. This commit changes the test expectation to also accept
"anonymous", which was already the case for similar expectations.
JoostK added a commit to JoostK/angular that referenced this issue Jan 7, 2021
…ction name

The "monitoring" workflow has been failing since angular#40127 was merged,
due to a Saucelabs test failure in Internet Explorer 11. The issue is
with the test's expectation which does not account for Ivy instruction
invocations to use "anonymous" instead of the instruction's function
name. This commit changes the test expectation to also accept
"anonymous", which was already the case for similar expectations.
atscott added a commit that referenced this issue Jan 7, 2021
…ction name (#40342)

The "monitoring" workflow has been failing since #40127 was merged,
due to a Saucelabs test failure in Internet Explorer 11. The issue is
with the test's expectation which does not account for Ivy instruction
invocations to use "anonymous" instead of the instruction's function
name. This commit changes the test expectation to also accept
"anonymous", which was already the case for similar expectations.

PR Close #40342
@angular-automatic-lock-bot
Copy link

@angular-automatic-lock-bot angular-automatic-lock-bot bot commented Feb 6, 2021

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Feb 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
No open projects
ng-linker
  
Done
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants