Skip to content

fix(angular): Add legacy support for Angular ValueAccessors#175

Open
poulpe38000 wants to merge 1 commit into
stenciljs:mainfrom
poulpe38000:angular-value-accessors-legacy-support
Open

fix(angular): Add legacy support for Angular ValueAccessors#175
poulpe38000 wants to merge 1 commit into
stenciljs:mainfrom
poulpe38000:angular-value-accessors-legacy-support

Conversation

@poulpe38000
Copy link
Copy Markdown
Contributor

  • add legacyValueAccessors flag to OutputTargetAngular type (false by default to keep the behaviour consistent with the current build process)
  • add non extended value accessors for angular < 9 support
  • update value accessors generator script to handle legacy support

With the addition of the empty @directive decorator, there is a breaking change with projects using angular < 9. To fix the issue, the users had to manually remove the decorator or move the extended code from the abstract ValueAccessor class to the other value accessors.
This PR intends to fix this by adding a legacy flag to the compiler that will do just this.
see: https://angular.io/guide/migration-undecorated-classes#im-a-library-author-should-i-add-the-directive-decorator-to-base-classes

* add legacyValueAccessors flag to OutputTargetAngular type (false by default to keep the behaviour consistent with the current build process)
* add non extended value accessors for angular < 9 support
* update value accessors generator script to handle legacy support
@poulpe38000 poulpe38000 changed the title Add legacy support for Angular ValueAccessors fix(angular): Add legacy support for Angular ValueAccessors Aug 30, 2021
@splitinfinities splitinfinities added the package: angular @stencil/angular-output-target package label Sep 20, 2021
@christian-bromann christian-bromann requested a review from a team as a code owner March 12, 2025 22:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: angular @stencil/angular-output-target package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants