[英]How Many Fragments Can I Host in an Activity?
I am developing an application and was just curious about the best practice regarding how many fragments to host in an activity. 我正在开发一个应用程序,并且只是好奇关于在一个活动中托管多少个片段的最佳实践。
I have a view that I am going to reuse throughout my application, and I want to continue using it as much as possible to display various fragments. 我认为我将在整个应用程序中重用,并且我想尽可能多地继续使用它以显示各种片段。 What is the recommended practice?
推荐的做法是什么? Is it safe from an app performance standpoint to load unlimited fragments in an activity?
从应用程序性能的角度来看,在活动中加载无限片段是否安全?
In the documentation i dont see a limits about how many fragment you can use, but... its good idea think before declare fragments, if you have a lot fragment you can start with problems about the "logic". 在文档中,我没有看到关于可以使用多少个片段的限制,但是...最好在声明片段之前考虑一下,如果您有很多片段,则可以从有关“逻辑”的问题开始。
First start with Mockups, Wireframes and Navigation, then you should know how many fragments or activities you need. 首先从模型,线框和导航开始,然后您应该知道需要多少片段或活动。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.