INNER CODE UNIT · Dart

_DemoStyleGate

maplibre/flutter-maplibre-gl · maplibre_gl_example/lib/main.dart:170

class _DemoStyleGate extends StatelessWidget {
  const _DemoStyleGate({required this.page});

  final ExamplePage page;

  @override
  Widget build(BuildContext context) {
    return FutureBuilder<void>(
      // Always the same future, so a rebuild here never starts a new probe.
      future: ExampleConstants.resolveDemoMapStyle(),
      builder: (context, snapshot) {
        if (snapshot.connectionState != ConnectionState.done) {
          return const Scaffold(
            body: Center(child: CircularProgressIndicator()),
          );
        }
        return page;
      },

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…