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

i18n: typescript integration #126

Draft
wants to merge 14 commits into
base: master
Choose a base branch
from
Draft

i18n: typescript integration #126

wants to merge 14 commits into from

Conversation

marpme
Copy link
Contributor

@marpme marpme commented Jan 19, 2022

No description provided.

@marpme marpme marked this pull request as draft January 19, 2022 07:03
@marpme marpme changed the title I18n typescript lib i18n: typescript integration Jan 19, 2022
Comment on lines +10 to +12
text: string,
plural?: string | { [key: string]: any },
options?: { [key: string]: any }
Copy link
Contributor Author

@marpme marpme Jan 19, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a really weird construct as the second option can be omitted, but you could still provide the 3rd one instead. Hence you have some weird typing allowances here ... 🤔

Info: this is the main i18n interface

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we maybe reconsider the API to make it simpler?
We also had some confusion with it, while adding declarations to workflow-client

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could potentially think of providing an alternative API entry point.

If we really want to modify this interface, then we might have to consider writing codemod for transforming previous calls in dependent project. (depending on the changes proposed)

First of all I actually wanted to ensure a bit of stability for this project as it hasn't been touch for a long time.

@marpme marpme closed this Apr 19, 2023
@marpme marpme deleted the i18n-typescript-lib branch April 19, 2023 05:39
@marpme marpme restored the i18n-typescript-lib branch May 2, 2023 05:16
@marpme marpme reopened this May 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants