android_ jetpack_ Notes on using data binding in xml layout
Reprinted from: https://www.jianshu.com/p/b923afeba8c0?utm_campaign=maleskine&utm_content=note&utm_medium=seo_notes&utm_source=recommendation
Notes on the use of databinding
1. Space.
Using spaces directly in xml will report errors.
MalformedByteSequenceException: Invalid byte 3 of 3-byte UTF-8 sequence.
You need to ...
Posted by segwaypirate on Wed, 13 Oct 2021 08:36:29 -0700
Android uses BottomNavigationView and navigation components to implement bottom navigation
The renderings are as follows:
Implementation steps:
Don't forget to add the required dependencies before working
implementation 'androidx.navigation:navigation-fragment:2.2.2'
implementation 'androidx.navigation:navigation-ui:2.2.2'
1, First, make preparations and create four fragments, corresponding layout files and menu files 1. Four ...
Posted by danmahoney245 on Sun, 10 Oct 2021 01:55:46 -0700
Why doesn't Compose have layout nesting problems?
Author: Ricardo mjiang
preface
Students who have done layout performance optimization know that in order to optimize the interface loading speed, the layout level should be reduced as much as possible. This is mainly because the increase of layout level may lead to the exponential growth of measurement time. Composition does not have this p ...
Posted by SteveMT on Thu, 30 Sep 2021 13:49:09 -0700
Jetpack AAC complete analysis Lifecycle fully mastered!
1, Introduction to Android Jetpack
1.1 what is jetpack
The official definition is as follows:
Jetpack is a suite composed of multiple libraries, which can help developers follow best practices, reduce template code, and write code that can run consistently in various Android versions and devices, so that developers can focus on writing im ...
Posted by gypmaster on Fri, 24 Sep 2021 21:47:23 -0700
Jetpack: Room database upgrade detailed actual combat!
Catalogue of series articles
Related articles: Jetpack: Room super detailed use pit guide! Jetpack:Room+kotlin collaboration? Transaction problem analysis, detailed explanation of withTransaction API Jetpack:Room use error FAQ Jetpack:Room is optimized with LiveData/Flow, and Room+Flow uses principle analysis.
Introduction to Room upg ...
Posted by falcon8253 on Sun, 19 Sep 2021 23:47:53 -0700
Use of LiveData in JetPack
1. Background
Like its name, LiveData is an observable data holder. Unlike conventional observable, LiveData has life cycle awareness, which means that it can correctly handle the life cycle in activities, fragments and services.
The data source of LiveData is generally ViewModel, or other components that can update LiveData. When the data ...
Posted by gary00ie on Fri, 03 Sep 2021 22:02:48 -0700