title: Flutter - Change the animation of TabBarView
body: <p>I implemented a basic TabBar and TabBarView with a DefaultTabController, see code below.</p>
  <pre><code>class MyApp2 extends StatelessWidget {
    @override
    Widget build(BuildContext context) {
      return DefaultTabController(
        length: BOTTOM_TABS,
        child: Scaffold(
          appBar: AppBar(title: const Text('Bottom App Bar')),
          body: _tabBarView(),
          bottomNavigationBar: _bottomTabBar(),
        ),
      );
    }
  
    _tabBarView() {
      return TabBarView(
        physics: NeverScrollableScrollPhysics(),
        children: [
          Container(
            color: Colors.blue,
          ),
          Container(
            color: Colors.orange,
          ),
          Container(
            color: Colors.lightGreen,
          ),
          Container(
            color: Colors.red,
          ),
        ],
      );
    }
  
    _bottomTabBar() {
      return TabBar(
        tabs: [
          Tab(
            icon: new Icon(Icons.home),
          ),
          Tab(
            icon: new Icon(Icons.public),
          ),
          Tab(
            icon: new Icon(Icons.group),
          ),
          Tab(
            icon: new Icon(Icons.person),
          )
        ],
      );
    }
  }
  </code></pre>
  <p>Works great! Now what I want to do is change the animation between the two tabs from the default animation. But I can't find an easy way to do that.</p>
  <p>After a bit of research it seems like I need to use a custom TabController and somehow use its <a href="https://docs.flutter.io/flutter/material/TabController/animateTo.html" rel="noreferrer">animateTo</a> method. To me that seems like a pretty big change just to change the animation.  <strong>What I wonder is if that is the correct way or if I am missing some easier way to just change the default animation between the tabviews?</strong></p>
  <p>If someone could give me some good resources to point me in the right direction I'd greatly appreciate it.</p>