Skip to content

Conversation

@revonateB0T
Copy link
Collaborator

No description provided.

@revonateB0T revonateB0T marked this pull request as ready for review December 11, 2024 08:35
@revonateB0T revonateB0T requested a review from FooIbar December 11, 2024 08:35
Copy link
Owner

@FooIbar FooIbar left a comment

Choose a reason for hiding this comment

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

We can't use data class as we want multiple layers of fallbacks, e.g. zh-HK -> zh-TW -> en.

@revonateB0T
Copy link
Collaborator Author

We can't use data class as we want multiple layers of fallbacks, e.g. zh-HK -> zh-TW -> en.

We can use data class.copy, but it seems data class hits jvm max method limit.

@revonateB0T
Copy link
Collaborator Author

@FooIbar reimplemented, PTAL.

Pros: cleanest way for translators to add new strings
Cons: 1. No compiler check to avoid us mutate strings 2.No compiler check to avoid duplicate translations

@revonateB0T revonateB0T changed the title Refine Strings Strings builder dsl Dec 11, 2024
@revonateB0T
Copy link
Collaborator Author

dex size decrease for 100KB as well

Copy link
Owner

@FooIbar FooIbar left a comment

Choose a reason for hiding this comment

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

I don't think this is the way. How do the translators check for missing translations? They could just remove the by EnStrings before.

@revonateB0T
Copy link
Collaborator Author

revonateB0T commented Dec 11, 2024

I don't think this is the way. How do the translators check for missing translations? They could just remove the by EnStrings before.

I don't think translators will use IDE or check for compiler message.
They just compare the whole file with EN file, so the cleanest way to add is better

@revonateB0T revonateB0T marked this pull request as draft December 11, 2024 12:53
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.

3 participants