title: BottomNavigationBarItem open respective page when clicked on the Icon
body: <p>I am looking for opening a page when I clicked on the Icon which is in BottomNavigationBarItem in the flutter. </p>
  
  <p>I tried with indexing but I am not able to understand is I put all my icons in a list then how to get it. </p>
  
  <pre><code> class CustomAppBar extends StatelessWidget {
   final List&lt;BottomNavigationBarItem&gt; bottomBarItems = [];
  
    final bottomNavigationBarItemStyle = TextStyle(fontStyle: 
      FontStyle.normal, color: Colors.black);
  
    CustomAppBar() {
     bottomBarItems.add(
     BottomNavigationBarItem(icon: Icon(Icons.home,color: Colors.brown,),
       title: Text("Explore", style: 
      bottomNavigationBarItemStyle.copyWith(color: Colors.green)),
       ),
    );
    bottomBarItems.add(new BottomNavigationBarItem(icon: new 
       Icon(Icons.favorite,color: Colors.black,),
        title: Text("Watchlist",style: bottomNavigationBarItemStyle,),
     ),
    );
     bottomBarItems.add(new BottomNavigationBarItem(icon: new 
        Icon(Icons.local_offer,color: Colors.black,),
         title: Text("Deals",style: bottomNavigationBarItemStyle,),
     ),
      );
    bottomBarItems.add(new BottomNavigationBarItem(icon: new 
     Icon(Icons.notifications,color: Colors.black,),
      title: Text("Notifications",style: bottomNavigationBarItemStyle,),
    ),
     );
     }
  
     @override
     Widget build(BuildContext context) {
     return Material(
       elevation: 15.0,
       child: BottomNavigationBar(
        items: bottomBarItems,
         type: BottomNavigationBarType.fixed,
        ),
       );
      }
     }
  
     /*class NewPage extends StatelessWidget {
    String title;
    NewPage(this.title);
     @override
     Widget build(BuildContext context) {
     return Scaffold(
     body: Center(child: Text(title),),
  
      );
      }
     }*/
  </code></pre>