{"id":16413253,"url":"https://github.com/hashirshoaeb/flutter-tales","last_synced_at":"2025-03-23T06:31:18.023Z","repository":{"id":114275250,"uuid":"244878714","full_name":"hashirshoaeb/flutter-tales","owner":"hashirshoaeb","description":"My journey as a Flutter developer, from zero to hero. Repo is my course work, including everything that I have learnt about flutter and dart. ","archived":false,"fork":false,"pushed_at":"2020-06-27T05:35:18.000Z","size":222,"stargazers_count":12,"open_issues_count":1,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-18T18:21:42.770Z","etag":null,"topics":["dart","flutter","flutter-app","flutter-demo","flutter-examples","flutter-practices","flutter-tales"],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hashirshoaeb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-03-04T11:04:45.000Z","updated_at":"2024-08-06T05:23:31.000Z","dependencies_parsed_at":"2023-07-18T14:16:10.153Z","dependency_job_id":null,"html_url":"https://github.com/hashirshoaeb/flutter-tales","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hashirshoaeb%2Fflutter-tales","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hashirshoaeb%2Fflutter-tales/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hashirshoaeb%2Fflutter-tales/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hashirshoaeb%2Fflutter-tales/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hashirshoaeb","download_url":"https://codeload.github.com/hashirshoaeb/flutter-tales/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245066496,"owners_count":20555402,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dart","flutter","flutter-app","flutter-demo","flutter-examples","flutter-practices","flutter-tales"],"created_at":"2024-10-11T06:50:58.761Z","updated_at":"2025-03-23T06:31:18.014Z","avatar_url":"https://github.com/hashirshoaeb.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- PROJECT LOGO --\u003e\n\u003cbr /\u003e\n\u003cp align=\"center\"\u003e\n  \u003ch1 align=\"center\"\u003eFlutter Tales 🚀\u003c/h1\u003e\n\n  \u003cp align=\"center\"\u003e\n    A Flutter project for practice and example codes.\n    \u003cbr /\u003e\n    \u003cbr /\u003e\n    \u003ca href=\"https://hashirshoaeb.com\"\u003eAbout Me\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/hashirshoaeb/flutter-tales/issues\"\u003eReport Bug\u003c/a\u003e\n    ·\n    \u003ca href=\"https://github.com/hashirshoaeb/flutter-tales/issues\"\u003eRequest Feature\u003c/a\u003e\n  \u003c/p\u003e\n\u003c/p\u003e\n\n![GitHub contributors](https://img.shields.io/github/contributors/hashirshoaeb/flutter-tales?color=ffcc66\u0026style=for-the-badge)\n![GitHub stars](https://img.shields.io/github/stars/hashirshoaeb/flutter-tales?color=ffcc66\u0026style=for-the-badge)\n[![GitHub forks](https://img.shields.io/github/forks/hashirshoaeb/flutter-tales?style=for-the-badge)](https://github.com/hashirshoaeb/star_book/network)\n[![GitHub issues](https://img.shields.io/github/issues/hashirshoaeb/flutter-tales?color=ffcc66\u0026style=for-the-badge)](https://github.com/hashirshoaeb/star_book/issues)\n[![GitHub license](https://img.shields.io/github/license/hashirshoaeb/flutter-tales?style=for-the-badge)](https://github.com/hashirshoaeb/flutter-tales/blob/master/LICENSE)\n[![Twitter Follow](https://img.shields.io/twitter/follow/hashirshoaeb?color=ffcc66\u0026logo=twitter\u0026logoColor=ffffff\u0026style=for-the-badge)](https://twitter.com/hashirshoaeb)\n\n## Apps\n\n- [Quiz App - Map Object key/value ](https://github.com/hashirshoaeb/flutter-tales/tree/master)\n- [Bank Transaction - List View and Scroller ](https://github.com/hashirshoaeb/flutter-tales/tree/second_app)\n- [Advice App - Async Api Caller ](https://github.com/hashirshoaeb/flutter-tales/tree/async-api-call)\n\n- [Permission App - Request App Permissions](https://github.com/hashirshoaeb/flutter-tales/tree/permission)\n\n## Lab work\n\n- [Lab 3 - Dart Programming - Classes](./READMEdocs/lab3.md)\n- [Lab 4 - Dart Programming - Classes Inheritance](./READMEdocs/lab4.md)\n- [Lab 5 - Dart Programming - List](./READMEdocs/lab5.md)\n- [Lab 6 - Dart Programming - Abstract Classes and Interfaces](./READMEdocs/lab6.md)\n- [Lab 7 - Dart Programming - Exception Handling](./READMEdocs/lab7.md)\n- [Lab 8 - Dart Programming – Functions](./READMEdocs/lab8.md)\n- [Lab 9 - Dart Programming – Maps](./READMEdocs/lab9.md)\n- [Lab 10 - Dart Programming – Sets](./READMEdocs/lab10.md)\n- [Lab 11 - Dart Programming – Mixin](./READMEdocs/lab11.md)\n\n## Assignments\n\n- [Assignment 1](https://github.com/hashirshoaeb/flutter-tales/tree/Assignment-1)\n\n  Instead of using maps, do the same thing using class or structure [link](https://github.com/hashirshoaeb/flutter-tales/tree/Assignment-1)\n\n- [Assignment 2](https://github.com/hashirshoaeb/flutter-tales/tree/Assignment-2)\n\n  To improve the UI of Transaction App [link](https://github.com/hashirshoaeb/flutter-tales/tree/Assignment-2)\n\n## Getting Started\n\nA few resources to get you started if this is your first Flutter project:\n\n- [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab)\n- [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook)\n\nFor help getting started with Flutter, view\n[online documentation](https://flutter.dev/docs), which offers tutorials,\nsamples, guidance on mobile development, and a full API reference.\n\n## Method to Run\n\nIn order to run your application from terminal, type:\n\n```bash\n  $flutter emulators\n```\n\nShows available emulators.\n\n- To run an emulator, run 'flutter emulators --launch \u003cemulator id\u003e'.\n- To create a new emulator, run 'flutter emulators --create [--name xyz]'.\n\n```bash\n  $flutter emulators --launch iOS Simulator\n```\n\n```bash\n  $cd first_app\n  $flutter run\n```\n\n# DART\n\n## What is Dart\n\nDart is an **object oriented programming language**. It is primarily used for creating frontend user interfaces. And it is **strongly typed**.\n\n## Variables, Functions, Types\n\nVariables are used to temporarily store data.\n\n```dart\n var name = 'Hashir';\n print(name); // Outputs ‘Hashir’\n```\n\nHere, **var** keyword is used to create variable. **Equal(=)** operator is used to assign value to the variable. And **print()** function is used to log the output.\n\nTip: It's common to use **camelCase** notation to name the variable.\n\nIn above example, variable **name** is of type **String**. Since Dart is able to **infer the type though** (because you initialise the variable with a value - 'Hashir'). It can also be written as follows.\n\n```dart\nString name = 'Hashir';\nprint(name); // Outputs 'Hashir'\n```\n\n**Types** describe the type of data of a variable. With types, you can ensure that a certain code expression only accepts numbers and the compiler “yells at you” if you pass wrong data.\n\n| Type             | Example                            | More Information                                                                                                                                      |\n| ---------------- | ---------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |\n| String           | String myName = 'Max';             | Holds text. You can use single or double quotes - just be consistent once you made your choice.                                                       |\n| num, int, double | int age = 30; double price = 9.99; | num refers to “number” - there are two types of numbers in Dart: Integers (numbers without a decimal place) and doubles (numbers with decimal places) |\n| object           | Person = Person();                 | Generally, everything in Dart is an object - even an integer. But objects can also be more complex, see below.                                        |\n\n**Functions** allow you to define code snippets which you can call whenever and as often as you want.\n\n```dart\nvoid sayHello(String name) {\n  print('Hello ' + name);\n}\n\ndouble addNumbers(double n1, double n2) {\n  return n1 + n2;\n}\n\n```\n\n## Objects \u0026 Object-orientation\n\nDart is an object-oriented programming language - that means that **every value in Dart is an object**, even primitive values like text (= String) or numbers (= Integers and Doubles).\n\nObjects are data structures and created with the help of “Classes” because every object needs a blueprint (=\u003e the class) based on which you can then create (“instantiate”) it.\n\n```dart\nclass Person {\n  var name = 'Max';\n  var age = 30;\n\n  void greet() {\n  print('Hi, I am ' + name + ' and I am ' + age.toString() + ' years old!';\n  }\n}\n```\n\nThe class only serves as a blueprint though! On its own, it does not give you an object! Instead, you can now create objects based on this class:\n\n```dart\nvoid main() {\n  var myself = Person();\n  print(myself.name); // use the . to access class properties \u0026 methods\n}\n```\n\n## Positional \u0026 Named Arguments\n\n- annonymus function jiska koi nam na ho,\n- press 'Command' and hover the class object, to\n\n* final vs const\n  final is called a run time constant. when you code and made final, but you dont know the value to it,\n  but know know what are you assigning to const eg:\n\n# Flutter\n\n- Pascel notation\n- class is a widget\n- we are creating a widget tree\n- extend use to inherite\n- this is a builder widget.\n- flutter takes the control on screen pixcels\n- every widget in flutter is actaully a dart class with a - build method.\n- Scaffold is a design widget\n\nStateless widgets are immutable, meaning that their properties can’t change—all values are final.\nTwo types of widgets:\n\n- Stateless - which does not save the state\n- Statefull - which maintains the state - like cookies, login sessions\n\nthere are two type of arguments like in python,\npositional aggumaents , named arguments\nStateful widgets maintain state that might change during the lifetime of the widget. Implementing a stateful widget requires at least two classes: 1) a StatefulWidget class that creates an instance of 2) a State class. The StatefulWidget class is, itself, immutable, but the State class persists over the lifetime of the widget.\nflutter has control on each and every pixel of screen.\n\nvisible widget. =\u003e for handling input and output, eg. button\ninvisible widget =\u003e for handling layout and control eg. column\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhashirshoaeb%2Fflutter-tales","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhashirshoaeb%2Fflutter-tales","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhashirshoaeb%2Fflutter-tales/lists"}