chill-chinese / stroke-order-animator

Stroke order animations and quizzes for Chinese characters in Flutter.
https://chill-chinese.github.io/stroke-order-animator/
BSD 3-Clause "New" or "Revised" License
87 stars 24 forks source link

Example missing pubspec #1

Closed josh-burton closed 4 years ago

josh-burton commented 4 years ago

Hey! Awesome work getting started on this. I'd love to give it a try but it seems the example app is missing a pubspec and can't be run.

Mr-Pepe commented 4 years ago

What's the error message you get? When I clone the repo and execute flutter run I get "Target file "lib/main.dart" not found". Simply copying the main.dart from the example folder to the lib folder worked fine.

Let me know if that helps and I'll update the docs.

Mr-Pepe commented 4 years ago

I updated the package, committed the main.dart to the lib folder, but moved it to the example folder when publishing to pub. That seems a bit cumbersome but this way you see it as an example on pub, but can also directly build it when cloning the repo. This is my first pub package, so I don't know what the best practice is.

josh-burton commented 4 years ago

The example folder should be an entire flutter app which depends on the package. I'd suggest recreating the package with the Flutter tool so it will create the create structure for you, and copy in your classes.

Mr-Pepe commented 4 years ago

Done. Thanks for the hint and feel free to give it a try.

josh-burton commented 4 years ago

Great, that looks much better. The sample app runs nicely!

Do you have plans to implement the ability to draw strokes?

Mr-Pepe commented 4 years ago

Good to hear!

Yes, I want to look into a quiz mode within the next two weeks or so.

Mr-Pepe commented 4 years ago

I haven't updated the docs yet, but I have implemented a basic quiz mode. Feel free to check it out :)

josh-burton commented 4 years ago

oh wow that's awesome, working well already!