Skip to content

Commit

Permalink
🎉 Version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
HofmannZ committed Jul 20, 2018
1 parent cfb027b commit 8053510
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 2 deletions.
38 changes: 38 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,41 @@
## [0.6.0] - July 19 2018

### Breaking change

- The library now requires your app to be wrapped with the `GraphqlProvider` widget @HofmannZ
- The global `client` variable is no longer available. Instead use the `GraphqlConsumer` widget

#### Fixes / Enhancements

- Added the `GraphqlProvider` widget. The client is now stored in an `InheritedWidget`, and can be accessed anywhere within the app.

```dart
Client client = GraphqlProvider.of(context).value;
```

- Added the `GraphqlConsumer` widget. For ease of use we added a widget that uses the same builder structure as the `Query` and `Mutation` widgets.

> Under the hood it access the client from the `BuildContext`.
- Added the option to optionally provide the `apiToken` to the `Client` constructor. It is still possible to set the `apiToken` with setter method.

```dart
return new GraphqlConsumer(
builder: (Client client) {
// do something with the client
return new Container();
},
);
```

#### Docs

- Added documentation for the new `GraphqlProvider`
- Added documentation for the new `GraphqlConsumer`
- Changed the setup instructions to include the new widgets
- Changed the example to include the new widgets

## [0.5.4] - July 17 2018

### Breaking change
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ First depend on the library by adding this to your packages `pubspec.yaml`:

```yaml
dependencies:
graphql_flutter: ^0.5.4
graphql_flutter: ^0.6.0
```
Now inside your Dart code you can import it.
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: graphql_flutter
description: A GraphQL client for Flutter.
version: 0.5.4
version: 0.6.0
authors:
- Eus Dima <eus@zinoapp.com>
- Zino Hofmann <zino@zinoapp.com>
Expand Down

0 comments on commit 8053510

Please # to comment.