Skip to content

refactor(migrations): handle jit: true component templates in signal input migration#57347

Closed
devversion wants to merge 2 commits intoangular:mainfrom
devversion:handle-jit-true-templates
Closed

refactor(migrations): handle jit: true component templates in signal input migration#57347
devversion wants to merge 2 commits intoangular:mainfrom
devversion:handle-jit-true-templates

Conversation

@devversion
Copy link
Member

@devversion devversion commented Aug 12, 2024

Components with jit: true are not processed by the Angular compiler,
so we cannot ask the template checker for the parsed template; simply
because the template wasn't attempted to be parsed.

We still can migrate simple cases of such components, commonly seen in
unit tests. We do this by manually parsing the template and making use
of the reference fallback resolution that is also used for host bindings
(where we don't have any type check block information).

@devversion devversion added target: patch This PR is targeted for the next patch release area: migrations Issues related to `ng update`/`ng generate` migrations labels Aug 12, 2024
@devversion devversion requested a review from crisbeto August 12, 2024 15:37
@ngbot ngbot bot modified the milestone: Backlog Aug 12, 2024
@devversion devversion changed the title refactor(migrations): handle jit: true component templates in signal input migration refactor(migrations): handle jit: true component templates in signal input migration Aug 12, 2024
@angular-robot angular-robot bot added the area: performance Issues related to performance label Aug 12, 2024
… migration

Instead of exposing just the `ts.CompilerOptions`, we should expose the
actual Angular compiler options throuhgout the signal input migration.

This will be useful for parsing templates, in cases of JIT-opted
components.
…l input migration

Components with `jit: true` are not processed by the Angular compiler,
so we cannot ask the template checker for the parsed template; simply
because the template wasn't attempted to be parsed.

We still can migrate simple cases of such components, commonly seen in
unit tests. We do this by manually parsing the template and making use
of the reference fallback resolution that is also used for host bindings
(where we don't have any type check block information).
@devversion devversion force-pushed the handle-jit-true-templates branch from c116dd4 to 385bfc5 Compare August 12, 2024 19:57
@devversion devversion added action: merge The PR is ready for merge by the caretaker merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note labels Aug 12, 2024
@angular-robot angular-robot bot removed the area: performance Issues related to performance label Aug 12, 2024
@devversion devversion added action: presubmit The PR is in need of a google3 presubmit target: rc This PR is targeted for the next release-candidate and removed merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note target: patch This PR is targeted for the next patch release action: presubmit The PR is in need of a google3 presubmit labels Aug 12, 2024
@AndrewKushnir
Copy link
Contributor

This PR was merged into the repository by commit d608b85.

The changes were merged into the following branches: main, 18.2.x

AndrewKushnir pushed a commit that referenced this pull request Aug 12, 2024
…l input migration (#57347)

Components with `jit: true` are not processed by the Angular compiler,
so we cannot ask the template checker for the parsed template; simply
because the template wasn't attempted to be parsed.

We still can migrate simple cases of such components, commonly seen in
unit tests. We do this by manually parsing the template and making use
of the reference fallback resolution that is also used for host bindings
(where we don't have any type check block information).

PR Close #57347
AndrewKushnir pushed a commit that referenced this pull request Aug 12, 2024
… migration (#57347)

Instead of exposing just the `ts.CompilerOptions`, we should expose the
actual Angular compiler options throuhgout the signal input migration.

This will be useful for parsing templates, in cases of JIT-opted
components.

PR Close #57347
AndrewKushnir pushed a commit that referenced this pull request Aug 12, 2024
…l input migration (#57347)

Components with `jit: true` are not processed by the Angular compiler,
so we cannot ask the template checker for the parsed template; simply
because the template wasn't attempted to be parsed.

We still can migrate simple cases of such components, commonly seen in
unit tests. We do this by manually parsing the template and making use
of the reference fallback resolution that is also used for host bindings
(where we don't have any type check block information).

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

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 Sep 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: migrations Issues related to `ng update`/`ng generate` migrations target: rc This PR is targeted for the next release-candidate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants