-
Notifications
You must be signed in to change notification settings - Fork 26.5k
refactor(compiler-cli): remove i18n options from LinkerOptions
#41554
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
refactor(compiler-cli): remove i18n options from LinkerOptions
#41554
Conversation
4eab2e0
to
610b29d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I am not sure about the deprecation notice, given that partial compilation/the linker has not been stable so in and of itself I wouldn't consider this change as breaking. It is however true that a library that switches to partial compilation would indeed be breaking, as the application's compilation options are no longer considered (so no more legacy message ids nor is preserveWhitespaces
taken into account anymore). I notice you put this on the meeting agenda so let's discuss there. In any case, I think the deprecation notice can not go into a refactor commit as those are excluded from the changelog.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM for dev infra
610b29d
to
eb14e11
Compare
hi @petebacondarwin, I am unable to merge this because it has a merge conflict with the |
There were three options being made available to users of the linker: - ` enableI18nLegacyMessageIdFormat` - `i18nNormalizeLineEndingsInICUs` - ` i18nUseExternalIds` None of these should actually be configurable at linking time because partially-linked libraries have tighter restrictions on what i18n options can be used. This commit removes those options from the `LinkerOptions` interface. It was considered to add a check for backwards compatibilty to ensure that if these options were being passed, and were different to the expected defaults, we would throw an informative error. But from looking at the Angular CLI (the only known client of the linker) it has never been setting these options so they have already always been set to the defaults. BREAKING CHANGE: Linked libraries no longer generate legacy i18n message ids. Any downstream application that provides translations for these messages, will need to migrate their message ids using the `localize-migrate` command line tool. Closes angular#40673
eb14e11
to
1517e11
Compare
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
There were three options being made available to users of the linker:
enableI18nLegacyMessageIdFormat
i18nNormalizeLineEndingsInICUs
i18nUseExternalIds
None of these should actually be configurable at linking time
because partially-linked libraries have tighter restrictions on
what i18n options can be used.
This commit removes those options from the
LinkerOptions
interface.It was considered to add a check for backwards compatibilty to ensure
that if these options were being passed, and were different to the expected
defaults, we would throw an informative error. But from looking at the
Angular CLI (the only known client of the linker) it has never been setting
these options so they have already always been set to the defaults.
BREAKING CHANGE:
Linked libraries no longer generate legacy i18n message ids. Any downstream
application that provides translations for these messages, will need to
migrate their message ids using the
localize-migrate
command line tool.Closes #40673