-
-
Notifications
You must be signed in to change notification settings - Fork 191
Description
Hello, I love hooks and I love Flutter. I want to make hooks the de-facto way we write widgets in Flutter, so I want to lower the barrier to entry with snazzy documentation.
Here are some problems I want to solve:
- Example coverage of features in the package. (number of features which have examples)
- Effort required to understand the examples. For some of us, this may be easy, just read the code! But for newcomers, seeing is believing. We should be able to share our examples easily!
Here's what I have so far
I have written an example for useAnimationController and hosted the example project using Github Pages. Try it out! https://leecommamichael.github.io/flutter_hooks/#/
If we move in this direction, we can add a build-step in the travis.yml to update the documentation. We can embed the app (which is hosted by GitHub Pages) in our generated Dart documentation or the Readme. I know that dartdoc can embed HTML in iframes, which is perfect. I'm unsure if Markdown can do the same for our README. To make give context when viewing docs, I can have the navigator present the example for the hook the user is looking at in the dart doc page.
It'd be ideal to use something like https://dartpad.dartlang.org/embed-flutter.html, but we'd have to implement it ourselves in order to pull the flutter_hooks package in.
What does everyone think? Do you also find this valuable? Is this a good approach, should I continue?