Dart Koans. Achieve enlightenment through failure.

Related tags

Templates dart_koans
Overview

Dart Koans

This application is inspired by Ruby Koans. The idea is simple: You achieve enlightenment though a process of failures. As each failure is overcome you get one step closer to enlightenment.

In practice, the Dart Koans allow you to learn Dart through a much more hands on approach. Each test is accompanied by enough comments surrounding the code that an individual should be able to determine what the code is trying to accomplish and what values need to be provided to the default fill-in value.

Installation

In order to properly complete the koans, you will need to edit the files, as well as run the script. As such it is recommended that you download the .zip file and extract it to a local directory. Once downloaded to a local directory, you may need to run pub install in the directory to copy over the required sdk files. Do Not use pub to download and install the Koans to another project, as it will place the source files in the pub-cache and more difficult location for editing properly.

Usage

First you must make sure you have, at the least, the Dart VM installed on your computer and working. If you're unsure about this process please see the Dart download. From the command line use the dartVM to run the file:

dart bin/dart_koans.dart

You should receive an error letting you know where your path to enlightenment is currently blocked. From there, edit the file either with your favorite CLI editor, or with the Dart Editor.

Modify the file to correct the error, save and run the application again. Continue until enlightenment is achieved.

At current time, it is recommended that you run the application from the command line, and not from the Dart Editor. This is until one of two bugs are resolved: Issue 4654 and Issue 2789

Notice

If you load the project in the Dart Editor, you can expect to see several warnings and hints about the project in various files. This is to be expected, as each test is designed to fail in order to highligh specifics about the Dart language.

Also Note: This is currently still very unstable and a work in progress. There are numerous areas which are subject to change as development progresses.

You might also like...

Target the specific design of Material for Android and Cupertino for iOS widgets through a common set of Platform aware widgets

Target the specific design of Material for Android and Cupertino for iOS widgets through a common set of Platform aware widgets

Flutter Platform Widgets This project is an attempt to see if it is possible to create widgets that are platform aware. Currently in order to render t

Jan 4, 2023

A token auction website made by Flutter thats interacts with Ethereum web3 through flutter_web3 package.

A token auction website made by Flutter thats interacts with Ethereum web3 through flutter_web3 package.

flutter_web3_auction A token auction website made by Flutter thats interacts with Ethereum web3 through flutter_web3 package. This flutter web package

Dec 26, 2022

Flutter package to diplay progress through a milestone progress widget

Flutter package to diplay progress through a milestone progress widget

milestone_progress Flutter package for IOS and Android to display progress through milestone progress widget. Screenshots ## Usage [Example]https://gi

Aug 4, 2020

A beautifully crafted app that takes you through an onboarding experience

A beautifully crafted app that takes you through an onboarding experience

Onboarding App davidcobbina.com Beautifully crafted with flutter and love, a useful UI Kit for developers and designers who want to kick start their a

Dec 3, 2022

Show movie & crews information through network. made by flutter

Show movie & crews information through network. made by flutter

1. Release Google Play App Store 20.03.14 updated Comming Soon 2. REST API https://developers.themoviedb.org/3 3. Screen shot Youtube 4. Design Petter

Dec 12, 2022

Draggable Scrollbar - A scrollbar that can be dragged for quickly navigation through a vertical list.

Draggable Scrollbar - A scrollbar that can be dragged for quickly navigation through a vertical list.

A scrollbar that can be dragged for quickly navigation through a vertical list. Additionaly it can show label next to scrollthumb with information about current item, for example date of picture created

Dec 10, 2022

App that simulates a flow of screens for the course of navigation and routes with nuvigator through Flutter

App that simulates a flow of screens for the course of navigation and routes with nuvigator through Flutter

Rotas app App que simula um fluxo de telas para o curso de navegação e rotas com

Dec 19, 2021

A flutter application that allows users to test their knowledge through quizzes made for specific topics.

Quiz_App A flutter application that allows users to test their knowledge through quizzes made for specific topics. Setup The application consists of a

Dec 29, 2021

Brewcrew - Brew Crew app use firebase through flutter

Brewcrew - Brew Crew app use firebase through flutter

Brew Crew In this new FLutter app I folowed the Net Ninja's Series on how to use

Jun 18, 2022
Comments
  • Fixes project to work with Dart v1.0.0.3_r30188 (and, hopefully, higher)

    Fixes project to work with Dart v1.0.0.3_r30188 (and, hopefully, higher)

    This project doesn't compile with Dart version 1.0.0.3_r30188 due to a breaking change that removes a method called "runAsync". I'm not entirely sure about the details since I'm trying to learn Dart, but I managed to get it working by upgrading the dependencies (path and unittest) to their latest versions and hacking together a fix for the change in the "path" API (namely, Builder was removed and replaced with Context).

    opened by dzrw 2
  • Unhandled exception in M4 with pubspec.lock on unittest and meta set to 0.5.11+1

    Unhandled exception in M4 with pubspec.lock on unittest and meta set to 0.5.11+1

    I was receiving an error Exception: No constructor 'Future.immediate' declared in class 'Future'. and saw that unittest and meta were locked to 0.4.5 and also found this thread -

    So I changed the pubspec.lock to allow the libraries to be updated - now I have a different error....

    Unhandled exception: RangeError: 3 #0 List. #1 ConfigKoans.onSummary (package:dart_koans/src/config_koans.dart:101:49) #2 _completeTests (package:unittest/unittest.dart:800:20) #3 _nextBatch (package:unittest/unittest.dart:771:21) #4 runTests.runTests. (package:unittest/unittest.dart:718:15) #5 _asyncRunCallback._asyncRunCallback (dart:async/event_loop.dart:15:17) #6 _asyncRunCallback._asyncRunCallback (dart:async/event_loop.dart:25:9) #7 Timer.Timer. (dart:async-patch/timer_patch.dart:9:15) #8 _Timer._createTimerHandler._handleTimeout (timer_impl.dart:99:28) #9 _Timer._createTimerHandler._handleTimeout (timer_impl.dart:107:7) #10 _Timer._createTimerHandler. (timer_impl.dart:115:23) #11 _ReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:81:92)

    opened by thetechnaddict 2
  • 3 Tests always pass

    3 Tests always pass

    A change in the unittest library in dart causes any test which throws an exception/error to automatically match if the throwsXXX matcher is contained as an expected value. It does not compare against actual but rather assumes the error that is thrown from the test itself.

    See: Bug 6761

    bug 
    opened by butlermatt 1
  • Updated for running koans with Dart2

    Updated for running koans with Dart2

    From what I could see, these koans are the most referenced Dart koans online, but they were not updated to work with Dart2.

    • Replaced dart-sdk requirement to ^2.3.0
    • Replaced legacy unittest dep with test.
    • Most change in code due to change in testing API (isInstanceOf has been deprecated, using isA instead)
    opened by ericomine 1
Owner
Matthew Butler
Matthew Butler
A beautiful app to help you achieve your goals🎯

Goalkeeper ?? A neat, nice looking Flutter app to keep track of your goals! It can be built for iOS and Android, and is available for free on the Play

Urmil Shroff 40 Dec 28, 2022
RelativeScale is a simple custom sizing system for flutter widgets to achieve the same physical sizes across different devices.

RelativeScale is a simple custom sizing system for flutter widgets to achieve the same physical sizes across different devices. Usage It is VERY easy

xamantra 19 Nov 25, 2022
Flutter package that provides you custom clippers to help you achieve various custom shapes.

flutter_custom_clippers Flutter package that provides you custom clippers to help you achieve various custom shapes. Usage To use this plugin, add flu

Damodar Lohani 291 Dec 23, 2022
SmallTask - Take small steps to achieve big things

SmallTask - Take small steps to achieve big things. Have you ever felt that when you are working on a project you kinda get confused about what to do?

Yuji 2 Mar 7, 2022
Flutter remote control - The main use of LongPressDraggable and DragTarget to achieve the universal remote control interaction effect.

Flutter remote control - The main use of LongPressDraggable and DragTarget to achieve the universal remote control interaction effect.

唯鹿 165 Jan 2, 2023
An app to save money and achieve your goal! Available on iOS & Android 🚀

BudgetMe An app that helps you save money and achieve your goal! Screenshots TestFlight & Google Play Beta License About This is an app to save money

Carlton Aikins 31 Nov 27, 2022
Achieve ~60 FPS, no matter how heavy the tree is to build/layout

flutter_smooth Achieve ~60 FPS, no matter how heavy the tree is to build/layout. ?? 3-second video output_small.mp4 (left = without smooth, right = sm

fzyzcjy 1k Jan 9, 2023
Target the specific design of Material for Android and Cupertino for iOS widgets through a common set of Platform aware widgets

Flutter Platform Widgets This project is an attempt to see if it is possible to create widgets that are platform aware. Currently in order to render t

null 1.3k Jan 4, 2023