Completed Tasks
Started Learning Flutter and Dart from the Udemy Course along with miscellaneous readings
Completed the first section of the course
- Objective: Create a flutter project to simulate Dice ie. as a button on the screen is clicked the UI changes randomly and a new number is shown on the app UI
- Project Link: Github Project: Dice Simulation
Concepts learnt
How Dart Works?
Significance of “const” keyword
- “const” keyword is used for performance improvement in Flutter. When used before a object (Widget), the object is cached in the memory, thereby making it easier to access when need.
- Stackoverflow - “const” vs “final”
Variable declaration in Dart
- Coming from the Python, the variable declaration is bit complicated in Dart. Though I have not mapped my head around the variable declaration as yet, but still they way things are done are “interesting” to say at least.
- Variables - Official Flutter Documentation
“this” keyword in Dart
- This is just like how “self” is used in Python. “self” is used to refer value for the specific class instance, “this” does the same thing in Dart.
- Stackoverflow - Usage of “this” keyword in Dart
Stateful vs Stateless Widgets
- “State” in simplistic terms refers to the changes done in the UI
- Stateful essentially means that widget can be programmed to change the UI of the app, this behaviour does not work in the case of “Stateless” widget
- Stackoverflow - Stateful vs Stateless Widget