|
| 1 | +# Flutter Searchbox Contribution Guide 🔍 |
| 2 | + |
| 3 | +Welcome to the contribution guide! We welcome all contributions. You can see the list of open issues over [here](https://github.com/appbaseio/flutter-searchbox/issues). If you're interested in picking up something, feel free to start a discussion 😺 |
| 4 | + |
| 5 | +The searchbox monorepo contains the code for the headless core(`searchbase`) and the searchbox UI widgets for flutter(`flutter_searchbox`). Project specific README files are available inside each package. |
| 6 | + |
| 7 | +## Initial setup |
| 8 | + |
| 9 | +1. Fork the repository in order to send PRs |
| 10 | + |
| 11 | +2. Clone the repo from your profile, use SSH if possible. Read more about it over [here](https://help.github.com/articles/connecting-to-github-with-ssh/). |
| 12 | + |
| 13 | +3. `cd` into the project directory |
| 14 | + |
| 15 | +4. Checkout the `master` branch (should be default) |
| 16 | + |
| 17 | +5. Install flutter SDK. Please follow the instructions mentioned at [here](https://flutter.dev/docs/get-started/install/macos). |
| 18 | + |
| 19 | + |
| 20 | +## Searchbase |
| 21 | + |
| 22 | +- Searchbase dart code is located at [here](https://github.com/appbaseio/flutter-searchbox/tree/master/searchbase/lib). |
| 23 | + |
| 24 | +- To run an example follow the below steps: |
| 25 | + |
| 26 | +1. `cd` into the example |
| 27 | +```bash |
| 28 | +cd searchbase/example/basic |
| 29 | +``` |
| 30 | + |
| 31 | +2. Install dependencies |
| 32 | +```bash |
| 33 | +flutter pub get |
| 34 | +``` |
| 35 | +3. Activate webdev |
| 36 | +```bash |
| 37 | +flutter pub global activate webdev |
| 38 | +``` |
| 39 | +4. Run the example |
| 40 | +```bash |
| 41 | +webdev serve |
| 42 | +``` |
| 43 | + |
| 44 | +The web examples depend relatively on the `searchbase` package so you can make the changes in the lib and test on the fly. |
| 45 | + |
| 46 | +**Note:** If you see any issue while running the example please check the [installation guide](https://dart.dev/tutorials/web/get-started) for dart web. |
| 47 | + |
| 48 | +## Flutter Searchbox |
| 49 | + |
| 50 | +- Flutter searchbox provides ready-to-use UI widgets to build search UIs for flutter apps. It uses the `searchbase` library to manage the state of the active search widgets. |
| 51 | +- It is located at [here](https://github.com/appbaseio/flutter-searchbox/tree/master/flutter_searchbox). |
| 52 | +- If you want to watch for the changes in the `searchbase` lib then use a relative path instead of the direct dependency at [here](https://github.com/appbaseio/flutter-searchbox/blob/master/flutter_searchbox/pubspec.yaml#L14). |
| 53 | + |
| 54 | +- To run an example follow the below steps: |
| 55 | +1. `cd` into the example |
| 56 | +```bash |
| 57 | +cd flutter_searchbox/example |
| 58 | +``` |
| 59 | + |
| 60 | +2. Open ios simulator |
| 61 | +```bash |
| 62 | +Open -a Simulator.app |
| 63 | +``` |
| 64 | + |
| 65 | +3. Install dependencies |
| 66 | +```bash |
| 67 | +flutter pub get |
| 68 | +``` |
| 69 | + |
| 70 | +4. Run the example |
| 71 | +```bash |
| 72 | +flutter run |
| 73 | +``` |
| 74 | + |
| 75 | +<hr /> |
0 commit comments