graphql_flutter 5.0.0-nullsafety.1 copy "graphql_flutter: ^5.0.0-nullsafety.1" to clipboard
graphql_flutter: ^5.0.0-nullsafety.1 copied to clipboard

outdated

A GraphQL client for Flutter, bringing all the features from a modern GraphQL client to one easy to use package.

example/lib/main.dart

import 'package:flutter/material.dart';
import './graphql_bloc/main.dart' show GraphQLBlocPatternScreen;
import './graphql_widget/main.dart' show GraphQLWidgetScreen;
import 'fetchmore/main.dart';

void main() => runApp(
      MaterialApp(
        title: 'GraphQL Flutter Demo',
        theme: ThemeData(
          primarySwatch: Colors.blue,
        ),
        home: Builder(
          builder: (BuildContext context) => Scaffold(
            appBar: AppBar(
              title: const Text('GraphQL Demo App'),
            ),
            body: Center(
              child: Column(
                children: <Widget>[
                  ElevatedButton(
                    onPressed: () {
                      Navigator.push(
                        context,
                        MaterialPageRoute<GraphQLWidgetScreen>(
                          builder: (BuildContext context) =>
                              GraphQLBlocPatternScreen(),
                        ),
                      );
                    },
                    child: const Text('GraphQL BloC pattern'),
                  ),
                  ElevatedButton(
                    onPressed: () {
                      Navigator.push(
                        context,
                        MaterialPageRoute<GraphQLWidgetScreen>(
                          builder: (BuildContext context) =>
                              const GraphQLWidgetScreen(),
                        ),
                      );
                    },
                    child: const Text('GraphQL Widget'),
                  ),
                  ElevatedButton(
                    onPressed: () {
                      Navigator.push(
                        context,
                        MaterialPageRoute<FetchMoreWidgetScreen>(
                          builder: (BuildContext context) =>
                              const FetchMoreWidgetScreen(),
                        ),
                      );
                    },
                    child: const Text('Fetchmore (Pagination) Example'),
                  ),
                ],
              ),
            ),
          ),
        ),
      ),
    );
866
likes
0
points
326k
downloads

Publisher

verified publisherzino.company

Weekly Downloads

A GraphQL client for Flutter, bringing all the features from a modern GraphQL client to one easy to use package.

Homepage
Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

connectivity, flutter, gql_exec, graphql, hive, meta, path, path_provider, plugin_platform_interface

More

Packages that depend on graphql_flutter