Fragments work as an activity? [duplicate]

0

I have seen that to continue using a Navigation Drawer, do I have to use Fragments, or can I use activity? or is there no difference between the two?

    
asked by anonymous 12.10.2017 / 20:37

1 answer

2

The idea of Fragment is to represent behavior or a user interface within a Activity . At Activity you can have multiple Fragment . And you can even use Fragment in other Activity . This makes it possible to write more componentized and reusable Android applications.

    
12.10.2017 / 20:47