Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kaboc/pubdev-explorer
An app to explore and bookmark packages hosted on pub.dev.
https://github.com/kaboc/pubdev-explorer
flutter-app flutter-example
Last synced: 3 days ago
JSON representation
An app to explore and bookmark packages hosted on pub.dev.
- Host: GitHub
- URL: https://github.com/kaboc/pubdev-explorer
- Owner: kaboc
- License: mit
- Created: 2022-11-11T05:55:12.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-16T10:51:06.000Z (6 months ago)
- Last Synced: 2024-05-16T11:32:47.729Z (6 months ago)
- Topics: flutter-app, flutter-example
- Language: JavaScript
- Homepage: https://kaboc.github.io/pubdev-explorer/
- Size: 6.23 MB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pub.dev explorer
An app to explore and bookmark packages hosted on [pub.dev](https://pub.dev/).
[**Web App**](https://kaboc.github.io/pubdev-explorer/)
## About this app
This is a sample app showcasing the following packages.
The app shows an example of how those packages are combined. The author himself,
however, is still examining and considering how they are made good use of to
make the app more maintainable and easier to evolve, so the current app design
is not necessarily the best.- [pottery](https://pub.dev/packages/pottery)
- A utility widget for [pot](https://pub.dev/packages/pot).
- Pot is an easy and safe DI solution. It is somewhat similar to providers
of pkg:riverpod in that the instance is assigned to a global variable and
can be accessed from anywhere, but different in that Pot is just a service
locator with only a few handy features and no complexity.
- Pottery limits the lifetime of Pots in the widget tree, making it possible
to use Pots in a similar manner to using MultiProvider of pkg:provider.
- [grab](https://pub.dev/packages/grab)
- A package to control rebuilds of a widget based on updates of a `Listenable`
such as `ChangeNotifier` and `ValueNotifier`.
- Usage is similar to `watch()` and `select()` of pkg:provider, but Grab
does not depend on the widget tree.
- Take it as an extension method version of `ValueListenableBuilder` with
filtering.
- [async_phase_notifier](https://github.com/kaboc/async-phase-notifier)
- A variant of `ValueNotifier` similar to AsyncNotifier of pkg:riverpod.
- `AsyncPhase` has one more phase "initial", which AsyncValue of Riverpod
does not have.
- `AsyncPhaseNotifier` provides a way to listen to errors, and there is also
`AsyncErrorListener` that is a widget with an error handler, convenient
for imperatively showing a message (e.g. showing a SnackBar) or for logging.
- [custom_text](https://pub.dev/packages/custom_text)
- A highly customisable text widget that decorates substrings and enables
tap / long-press / hover actions flexibly based on regular expression
patterns.
- Such decorations and actions are also available in text editing with
`CustomTextEditingController`, although the controller is not used in this
app.
## How to runJust run `flutter run` in the `app/` directory, with additional options if necessary.
## Code generation
The [drift](https://pub.dev/packages/drift) package used in this app requires
code generation. If you change the classes from which code is generated, run the
command below in the `core/` directory to regenerate the code.```shell
$ dart run build_runner build -d
```This project already contains generated code in `core/lib/src/generated/`, so
if you haven't changed anything, the above command is unnecessary.### Mock data for the web
The pub.dev API is not available on the web unfortunately, so mock data preset
in the app is used instead. The data contains the packages that were top 100
at some point in the past.### Mock data on other platforms
To use the mock data on platforms besides the web, set the `USE_MOCK`
environment variable to true as follows:```dart
flutter run --dart-define=USE_MOCK=true
```