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

Simplify and reduce overhead of lazy view binding in Fragments #4269

Merged

Conversation

cbeyls
Copy link
Contributor

@cbeyls cbeyls commented Feb 23, 2024

This reduces complexity of view binding inflation in Fragments, and also reduces overhead (no KProperty objects need to be generated by the compiler) by implementing Lazy instead of ReadOnlyProperty.

For a full explanation, see this detailed blog post.

@connyduck
Copy link
Collaborator

Oh this is very nice, thank you 😍
Please also link your blog post as a comment!

@cbeyls
Copy link
Contributor Author

cbeyls commented Feb 23, 2024

It's just a tiny code change really.
@connyduck You can add the link to the blog post in the merge commit (if you squash and merge).
Or do you need me to amend my commit to add the link in the comment?

@connyduck
Copy link
Collaborator

At the top of the file there currently is a link to a blog post with outdated information. I suggest you add another link so the next person looking at this file isn't confused and needs to dig into git history to find out whats going on.

@connyduck connyduck merged commit a19540f into tuskyapp:develop Feb 23, 2024
3 checks passed
@cbeyls cbeyls deleted the chore/improved_lazy_fragment_viewbinding branch February 27, 2024 22:57
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