alibaba / ARouter

💪 A framework for assisting in the renovation of Android componentization (帮助 Android App 进行组件化改造的路由框架)
Apache License 2.0
14.45k stars 2.61k forks source link

AGP8.0以上直接适配,无需修改原来写的代码 #1066

Open FlyJingFish opened 3 months ago

FlyJingFish commented 3 months ago

点此前往!!

andremw96 commented 3 months ago

how to test or check if the arouter-register is still working after implement your solution?

FlyJingFish commented 3 months ago

how to test or check if the arouter-register is still working after implement your solution?

When you delete classpath "com.alibaba:arouter-register:?" and still see the following log: (当你删除 classpath "com.alibaba:arouter-register:?" 还能看到如下日志的时候)

Load router map by arouter-auto-register plugin.
qq97241481 commented 2 months ago

但是我试了直接去掉 arouter的插件依赖,项目运行也没问题,各种跳转也不受影响,不知道为啥

FlyJingFish commented 2 months ago

但是我试了直接去掉 arouter的插件依赖,项目运行也没问题,各种跳转也不受影响,不知道为啥

额……你还没懂Arouter的原理。不谈原理直接简单粗暴一点解释就是,使用插件就是把相关的路径信息类找出来并写入安装包内,不使用插件就是在运行时动态的寻找这些类。使用插件的好处就是运行时不用寻找这些类了。ARouter用不用插件都可以跑起来,就看你如何选择了