Skip to content

ngc: support third-party codegen on install (ngc --init) #18810

Closed

Description

@alexeagle

Angular libraries ship without codegen (eg. ngfactory.js, ngsummary.js) so users need to compile these with ngc.
Right now this work is done for every run of ngc even though the libraries haven't changed. Doing this as an npm postinstall step would save time. Also it's needed for bazel.

Activity

  1. self-assigned this
    on Aug 21, 2017
  2. added
    featureLabel used to distinguish feature request from other issues
    on Aug 22, 2017
  3. chuckjaz commented on Aug 22, 2017

    @chuckjaz
    Contributor

    Blocking until runtime localization is available which then will generate a locale independent factories in the prepare step.

  4. added this to the Backlog milestone on Jan 23, 2018
  5. added a commit that references this issue on Sep 17, 2018
  6. LinboLen commented on Mar 26, 2019

    @LinboLen

    it works, but it takes me lots of time to figure it out.

  7. thesayyn commented on Apr 4, 2019

    @thesayyn

    Any update on this ?

  8. added a commit that references this issue on Dec 12, 2019
  9. added
    area: compilerIssues related to `ngc`, Angular's template compiler
    and removed
    area: coreIssues related to the framework runtime
    on Mar 12, 2020
  10. added
    P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
    and removed on Oct 1, 2020
  11. JoostK commented on Nov 25, 2020

    @JoostK
    Member

    I added this to the linker project as somewhat related, but upon further thought it may not be. Nowadays ngcc is precompiling libraries during postinstall, which is what is being requested in this issue. However, ngcc is an interim solution for compatibility, which the linker being the replacement. We are not currently planning to support a caching layer for the linker.

  12. alxhub commented on May 3, 2021

    @alxhub
    Member

    Closing as this is:

    1. not something we will support in View Engine, for reasons of deprecation
    2. the ultimate state will be that all libraries are shipped in partially compiled format and finalized with the Angular Linker, which is implemented as a Babel plugin. Babel supports caching, so a dedicated build author could implement similar functionality.
  13. angular-automatic-lock-bot commented on Jun 3, 2021

    @angular-automatic-lock-bot

    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.

  14. locked and limited conversation to collaborators on Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: compilerIssues related to `ngc`, Angular's template compilerfeatureLabel used to distinguish feature request from other issueshotlist: components teamRelated to Angular CDK or Angular Materialstate: blocked

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions