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

Add composable extensions #308

Closed
y9san9 opened this issue Mar 1, 2022 · 4 comments
Closed

Add composable extensions #308

y9san9 opened this issue Mar 1, 2022 · 4 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@y9san9
Copy link
Collaborator

y9san9 commented Mar 1, 2022

For Compose in android we have LocaleContext and we can use it:

// android and jvm
@Composable
expect fun StringDesc.localized(): String

// android 
@Composable
actual fun StringDesc.localized(): String = localized(LocalContext.current)

// jvm
@Composable
expect fun StringDesc.localized(): String = localized()
@y9san9
Copy link
Collaborator Author

y9san9 commented Mar 7, 2022

No, I'm looking for common definitions for that, to use with Compose MPP

@ghost
Copy link

ghost commented Mar 7, 2022

@y9san9 well it is, just not an extension function. You could fork and provide icerockdev an PR

@y9san9
Copy link
Collaborator Author

y9san9 commented Mar 7, 2022

So, as IceRock employee, I probably will do that after I finish my current task with JS platform for the library. This issue and others created by me are just reminders.

@icerockdev icerockdev deleted a comment Mar 8, 2022
@Alex009 Alex009 self-assigned this Mar 25, 2022
@Alex009 Alex009 added the enhancement New feature or request label Mar 25, 2022
@Alex009 Alex009 added this to the 0.19.0 milestone Mar 25, 2022
@Alex009 Alex009 mentioned this issue Mar 25, 2022
@Alex009 Alex009 closed this as completed Mar 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants