|
| 1 | +# Migrate your Flutter application to version 1.0.28 |
| 2 | + |
| 3 | +Starting with version 1.0.28, this repository is now separated in a pure dart (parse_server_sdk) and a flutter package (parse_server_sdk_flutter). |
| 4 | +This was done in order to provide a dart package for the parse-server, while keeping maintenance simple. |
| 5 | +You can find both packages in the package directory. |
| 6 | + |
| 7 | +### 1. pubspec.yaml |
| 8 | +In your projects pubspec.yaml at the dependencies section, you have to change |
| 9 | +``` |
| 10 | +dependencies: |
| 11 | + parse_server_sdk: ^1.0.27 |
| 12 | +``` |
| 13 | +to |
| 14 | +``` |
| 15 | +dependencies: |
| 16 | + parse_server_sdk_flutter: ^1.0.28 |
| 17 | +``` |
| 18 | +This is the current released version of the parse_server_sdk_flutter package: [](https://pub.dev/packages/parse_server_sdk_flutter) |
| 19 | + |
| 20 | +### 2. imports |
| 21 | +As the package name changed, you have to change |
| 22 | +``` |
| 23 | +import 'package:parse_server_sdk/parse_server_sdk.dart'; |
| 24 | +``` |
| 25 | + to |
| 26 | +``` |
| 27 | +import 'package:parse_server_sdk_flutter/parse_server_sdk.dart'; |
| 28 | +``` |
| 29 | +in every file. |
| 30 | + |
| 31 | +It is recommended to do so by the replacement feature of your IDE. |
| 32 | + |
| 33 | +### optional: provide app information on web |
| 34 | +As flutter web is now in beta, this SDK aims to be web compatible. |
| 35 | +But there are some parts completely different on web. For example, the wep-app cant determine it's name, version or packagename. |
| 36 | +That's why you should provide this information on web. |
| 37 | +```dart |
| 38 | +Parse().initialize( |
| 39 | + ... |
| 40 | + appName: kIsWeb ? "MyApplication" : null, |
| 41 | + appVersion: kIsWeb ? "Version 1" : null, |
| 42 | + appPackageName: kIsWeb ? "com.example.myapplication" : null, |
| 43 | +); |
| 44 | +``` |
| 45 | + |
| 46 | +### changed network library |
| 47 | +In order to provide a `ProgressCallback` for heavy file operations, |
| 48 | +the network library was switched from [http](https://pub.dev/packages/http) to [dio](https://pub.dev/packages/dio). |
| 49 | +There should be no breaking changes regarding this change, except if you are overriding the `ParseHTTPClient`. |
0 commit comments