Flutter : Where is the title of Material App used?

Question

Asked by Tushar R on May 31, 2018 (source).

The flutter app name is shown by the package name, the AppBar title is shown on the AppBar of the home page, so where does the title MaterialApp(title: 'Rectangle App',); is used in flutter projects.

import 'package:flutter/material.dart';

void main() => runApp(new MyApp());

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return new MaterialApp(
      debugShowCheckedModeBanner: false,
      title: 'Rectangle App',
      home: Scaffold(
        appBar: AppBar(
          title: Text('Rectangle App Home Page'),
        ),
        body: HelloRectangle(),
      ),
    );
  }
}

Answer

Question answered by Phuc T (source).

This is a good question. Below is the the explanation of how it is used:

A one-line description used by the device to identify the app for the user.

On Android the titles appear above the task manager's app snapshots which are displayed when the user presses the "recent apps" button. Similarly, on iOS the titles appear in the App Switcher when the user double presses the home button.

So in short:

  • On Android: it is used in Recent apps

  • On iOS: it is used in App switcher

Update 11th Feb, 2020:

The document is updated (I don't know exactly the updated time)

A one-line description used by the device to identify the app for the user. On Android the titles appear above the task manager's app snapshots which are displayed when the user presses the "recent apps" button. On iOS this value cannot be used. CFBundleDisplayName from the app's Info.plist is referred to instead whenever present, CFBundleName otherwise. To provide a localized title instead, use [onGenerateTitle].

So this value has no effect on iOS

DART FLUTTER
SHARE: