Skip to content

Commit

Permalink
Improve get started guide
Browse files Browse the repository at this point in the history
  • Loading branch information
passsy committed Dec 7, 2020
1 parent 314fc63 commit 28a6769
Showing 1 changed file with 45 additions and 14 deletions.
59 changes: 45 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,43 +11,74 @@
[![popularity](https://badges.bar/wiredash/popularity)](https://pub.dev/packages/wiredash/score)
[![pub points](https://badges.bar/wiredash/pub%20points)](https://pub.dev/packages/wiredash/score)

Wiredash is probably the easiest and most convenient way to capture in-app user feedback, wishes, ratings and much more. The SDK is completely written in Dart and runs on Android, iOS, Desktop and the Web. For more info, head over to [wiredash.io](https://wiredash.io).
Wiredash is probably the easiest, and most convenient way to capture in-app user feedback, wishes, ratings and much more. The SDK is completely written in Dart and runs on Android, iOS, Desktop and the Web. For more info, head over to [wiredash.io](https://wiredash.io).

## Getting Started
In order to get started, you need to create an account at [wiredash.io](https://wiredash.io) - you do this by simply signing in with a valid Google or GitHub account.
## Getting Started

Visit [docs.wiredash.io](https://docs.wiredash.io/guide/#integrating-wiredash-in-your-app) for the full documentation

### Setting up your Flutter project
## Quick start guide

After successfully creating a new project in the Wiredash admin console it's time to add Wiredash to your app. Simply open your `pubspec.yaml` file and add the current version of Wiredash as a dependency, e.g. `wiredash: 0.3.0`. Make sure to get the newest version.
### 1. Create a free account on [wiredash.io](https://console.wiredash.io)

Now get all pub packages by clicking on `Packages get` in your IDE or executing `flutter packages get` inside your Flutter project.
Sign in with a valid Google or GitHub account.

Head over to the main entry point of your app which most likely resides inside `main.dart`. In here wrap your root widget inside a `Wiredash` widget and provide your API credentials and your app's navigator key as parameters. That was already the hard part 🙌
### 2. Add wiredash to your pubspec.yaml.

```yaml
name: your_flutter_app
dependencies:
flutter:
sdk: flutter
wiredash: ^0.4.0
```
### 3. Wrap your root widget with Wiredash
Fill in the `projectId` and `secret` from [Wiredash console](https://console.wiredash.io) > Project > Settings

```dart
void main() => runApp(MyApp());
import 'package:flutter/material.dart';
import 'package:wiredash/wiredash.dart';
class MyApp extends StatelessWidget {
// It's important that Wiredash and your root Material- / Cupertino- / WidgetsApp
// share the same Navigator key.
final _navigatorKey = GlobalKey<NavigatorState>();
@override
Widget build(BuildContext context) {
return Wiredash(
projectId: "YOUR-PROJECT-ID",
secret: "YOUR-SECRET",
projectId: 'YOUR-PROJECT-ID',
secret: 'YOUR-SECRET',
navigatorKey: _navigatorKey,
child: MaterialApp(
navigatorKey: _navigatorKey,
title: 'Flutter Demo',
home: ...
home: YourSuperDuperAwesomeApp(),
),
);
}
}
}
```

Now you can call `Wiredash.of(context).show()` from anywhere inside your app to start the feedback process!
### 4. Launch the feedback flow

From anywhere in your app

```dart
ElevatedButton(
// launch wiredash where appropriate in your App
onPressed: () => Wiredash.of(context).show(),
child: Text('Give Feedback'),
),
```

![bottom sheet](https://deploy-preview-4--wiredash-docs.netlify.app/assets/img/wiredash-sample-app-side-by-side-start.09e3b5f2.png)

For more documentation, head over to [docs.wiredash.io](https://docs.wiredash.io/guide/#integrating-wiredash-in-your-app)

## Customization

### Setting user properties

Expand Down

0 comments on commit 28a6769

Please sign in to comment.