Custom Android Navigation Drawers

Dakshil Shah
1 min readMar 12, 2018

--

While recently working on a project, I realized that although Android Studio provides a default template for left hand navigation drawers, customizing it to create a menu using JSON data and also creating nested sub menu’s was difficult and online tutorials were not of much help, most only having some trivial part.

Also creating right hand navigation drawers that are fully customized and can be set to be accessible only if some option in the left hand drawer is selected(and also populate the drawers dynamically), was not well demonstrated online.

While I managed to create these features, I realized the need to document the process for future reference and thus also make it available to everyone else who also wishes to use these techniques.

The complete code for the tutorial will be hosted on GitHub. Please star or fork the same if you plan to use it as a template and provide the relevant attribution.

Tutorial breakup:

  1. 13 March, 2018; Part 1: Basic setup on Android Studio using navigation drawer template, creating a JSON data source, fetching and parsing JSON data
  2. Coming Soon; Part 2: Using data parsed in Part 1 to populate left hand navigation drawer with sub options, custom icons, change text color on selection with persistence.
  3. Coming Soon; Part 3: Right hand navigation drawer.
  4. Coming Soon; Part 4: Populate right hand navigation drawer with data depending on selection in left hand navigation drawer.

--

--