Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add flutter setup instructions #239

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions docs/docs/getting-started/flutter-setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Flutter Setup

After completing the [Rust setup](rust-setup.md) and setting up either [iOS setup](ios-setup.md) or [Android setup](android-setup.md), you're ready to create a cross-platform project using [Flutter](https://flutter.dev/). <br/>
Flutter is a framework for building natively compiled, multi-platform applications from a single codebase.

## Flutter plugin example

You can now clone the repository from [zkmopro/flutter-plugin](https://github.com/zkmopro/flutter-plugin) with

```sh
git clone https://github.com/zkmopro/flutter-plugin
```

Once cloned, follow the instructions in the README file to run the example app for the plugin.

<div style={{ display: 'flex', justifyContent: 'center', gap: '10px' }}>
<img src="/img/flutter-android.png" alt="First Image" width="250"/>
<img src="/img/flutter-ios.png" alt="Second Image" width="250"/>
</div>

## Use the flutter plugin

To use the plugin, update your `pubspec.yaml` file by adding the following dependency:

```yml
dependencies:
mopro_flutter:
# When depending on this package from a real application you should use:
# mopro_flutter: ^x.y.z
# See https://dart.dev/tools/pub/dependencies#version-constraints
# The example app is bundled with the plugin so we use a path dependency on
# the parent directory to use the current plugin's version.
path: <THE_PATH_TO_MOPRO_PLUGIN>
# e.g. path: ../flutter-plugin
```
3 changes: 2 additions & 1 deletion docs/sidebars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ const sidebars: SidebarsConfig = {
'getting-started/rust-setup',
'getting-started/ios-setup',
'getting-started/android-setup',
'getting-started/react-native-setup'
'getting-started/react-native-setup',
'getting-started/flutter-setup'
]
},
{
Expand Down
Binary file added docs/static/img/flutter-android.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/static/img/flutter-ios.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
35 changes: 35 additions & 0 deletions docs/versioned_docs/version-0.1.0/getting-started/flutter-setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Flutter Setup

After completing the [Rust setup](rust-setup.md) and setting up either [iOS setup](ios-setup.md) or [Android setup](android-setup.md), you're ready to create a cross-platform project using [Flutter](https://flutter.dev/). <br/>
Flutter is a framework for building natively compiled, multi-platform applications from a single codebase.

## Flutter plugin example

You can now clone the repository from [zkmopro/flutter-plugin](https://github.com/zkmopro/flutter-plugin) with

```sh
git clone https://github.com/zkmopro/flutter-plugin
```

Once cloned, follow the instructions in the README file to run the example app for the plugin.

<div style={{ display: 'flex', justifyContent: 'center', gap: '10px' }}>
<img src="/img/flutter-android.png" alt="First Image" width="250"/>
<img src="/img/flutter-ios.png" alt="Second Image" width="250"/>
</div>

## Use the flutter plugin

To use the plugin, update your `pubspec.yaml` file by adding the following dependency:

```yml
dependencies:
mopro_flutter:
# When depending on this package from a real application you should use:
# mopro_flutter: ^x.y.z
# See https://dart.dev/tools/pub/dependencies#version-constraints
# The example app is bundled with the plugin so we use a path dependency on
# the parent directory to use the current plugin's version.
path: <THE_PATH_TO_MOPRO_PLUGIN>
# e.g. path: ../flutter-plugin
```
3 changes: 2 additions & 1 deletion docs/versioned_sidebars/version-0.1.0-sidebars.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"getting-started/rust-setup",
"getting-started/ios-setup",
"getting-started/android-setup",
"getting-started/react-native-setup"
"getting-started/react-native-setup",
"getting-started/flutter-setup"
]
},
{
Expand Down
Loading