Notes
Flutter - Classes & Constructors
Classes & Constructors
class Person {
final String first;
final String last;
final String email;
Person : first = "none"; // …
Flutter - CLI New App
Create a New Application
- Create a new app
flutter create todo
- or with an org
flutter create --org run.cgrant todo
Flutter - Cocopods issues wite firebase - M1 issue
Had issues getting Flutter to connect to firebase. Had some cocopods issues. This seems to be a M1 Mac issue
Found a fix on this video …
Flutter - Code Basics
Code Basics
the main.dart file executes the app with the following convention
void main() => runApp(MyApp());
MyApp()
is a class that extends …
Flutter - Connecting to Firestore
Flutter - Connecting to Firestore
[[../../../_notes/_tech/Flutter/Flutter]]
Make sure you’ve configured your project using the instructions in …
Flutter - Creating Packages and reuseable modules
title: Flutter - Creating Packages and reuseable modules tags: [flutter]
how to create packages for reuse across multiple apps
Good write up on it: …
Flutter - Embed Dartpad
Flutter - Embed Dartpad
Flutter - File & Folder Structures
Key Files & Folders
Before getting into the coding lets refresh on the core concepts
- Lib: the core source files are under
/lib
- Main.dart: …
Flutter - Firebase Setup
Getting started
It used to be somewhat challenging to configure [[Firebase]] and [[../../../_notes/_tech/Flutter/Flutter]]. Now though they’ve …
Flutter - firestore-connections
2 Connecting to firestore
First add the dependency
open the file pubspec.yaml
and add the dependency for cloud_firestore
dependencies:
flutter: …
Flutter - HiveDB
Hive DB
This example explores the use of HiveDB for local storage in dart & flutter
Dependencies
HiveDB requires four …
Flutter - ios-google-signin
tips
Google sign in on ios crashes for me
this was a good thread https://github.com/flutter/flutter/issues/44564
As noted in that thread, I needed to …
Flutter - JSON from File
This example loads a sample dataset from a file and displays a random entry in the UI
Loading data from a static json file …
Flutter - List Filtering
List filtering
To get a subset of items from a List in flutter you can use the List.where()
method. The method loops over all …
Flutter - List Sorting
Flutter List Sorting
This example demonstrates how to sort a List of items.
Given a list of users and a sort order (isDecending) …
Flutter - ListView Dynamic Data
ListView with Dynamic Data
This example implements the common use case of displaying a ListView using a dynamic set of data from …
Flutter - MacOS Build
Flutter - MacOS Build
To make a local executable for mac:
From the terminal type flutter build macos
The app is create under: …
Flutter - Model Conventions
Once you review this, go look at [Freezed](https://pub.dev/packages/freezed) to simlify creation with generated classes
Utilize a lib/models
folder …
Flutter - Model Conventions
Flutter Model Conventions
Utilize a lib/models
folder for your classes
Utilize initializer lists
for simple setters instead of full constructors …
Flutter - Packages and Imports
Packages and Imports
Files can reference each other with standard paths following the package name.
Assuming the following structure
flutter_my_demo
- …
Flutter - Repository Pattern
Flutter Repository Pattern
This repo demonstrates using the repository pattern for layering your architecture.
In this design …
Flutter - State Management
Local state - State that can be contained within a single widget. Local or ephemeral state. setState & Stateful widget. State that only effects a …
Flutter - UI Quick Reference
Flutter - UI Quick Reference
Rounded Corners
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(12),
),
)
Font Style …
Flutter - YouTube Player
YouTube Player
This example explores playing youtube videos inside flutter apps.
The package youtube_player_flutter
has a sister …
Flutter Connecting to Firestore
Flutter Connecting to Firestore
[[../../../_notes/_tech/Flutter/Flutter]]
First add the dependency
open the file pubspec.yaml
and add the dependency …
Flutter for MacOS Distribution - Firestore Bug
Flutter for MacOS Distribution - Firestore Bug
I was building a app testing firestore and hapened to be using MacOS Desktop as the deploy target.
Come …
Flutter Google SignIn with iOS
Flutter Google SignIn with iOS
[[../../../_notes/_tech/Flutter/Flutter]]
Google sign in on ios crashes for me
this was a good thread …
Flutter Home
Flutter Development
You forgot everything again didn’t you 🙂
OK let’s try to get you back up to speed quicker this time.
Go through the …
Flutter ios-google-signin
Google sign in on ios crashes for me
[[../../../_notes/_tech/Flutter/Flutter]]
this was a good thread https://github.com/flutter/flutter/issues/44564 …
Flutter TOC
Flutter
Getting started
- Install Flutter
- [[flutter-top-10-vs-code-tips|Setup VS Code]]
- [[../Flutter - File & Folder Structures|Review File and …