{"repo":"theapache64/rebugger","free":true,"listed":false,"github":"https://github.com/theapache64/rebugger","clone":"git clone https://github.com/theapache64/rebugger.git","description":"A simple Compose Multiplatform library designed to print the reason for recomposition in your console/Logcat window.\"","language":"Kotlin","stars":1046,"topics":["android","jetpack","jetpack-compose","recomposition"],"license":"Apache-2.0","category":"mobile-apps","readme_excerpt":"🐞 Rebugger Rebugger : A recomposition debugger Being a “compose dev” our enemy number one is unnecessary recompositions 🤕. Often times we use tools like recompositionHighligher, LogComposition, and layout inspector to count the recomposition, but there’s no direct way to understand “why” the recomposition has happened. Rebugger is a simple compose utility function that can track the change in the given arguments. It’ll print the reason for recomposition in your Logcat window. ⌨️ Demo Usage 1. Add dependencies Kotlin Script Groovy 2. Add Rebugger call Call Rebugger with the states or args you want to track 3. See LogCat Search for Rebugger 🖥 Sample Outputs - When Rebugger hooked into your composable, it’ll print something like this - When VehicleUi recomposes due to car instance change - When VehicleUi recomposes due to both car and bike instance change - When VehicleUi recomposes due to human instance change (State within the composable) 🎨 Customization You can use the RebuggerConfig.init function to override default properties of Rebugger. 🔌 Plugin You can use the Rebugger IntelliJ plugin to generate the Rebugger function call. https://user-images.githubusercontent.com/9678279/235495156-445e7ced-30fa-41dd-9b37-84b80502187f.mov 🟠 Limitation Auto Name Picking When Rebugger is placed deep inside the composable, it may not be able to pick the correct composable name. For example, if I place the Rebugger somewhere inside the Button lambda like this It’ll print something lik","default_branch":null,"files":null,"tree":[],"storefront":"/r/theapache64","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/theapache64/rebugger/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}