Flutter Heroes
26.1K subscribers
272 photos
2 videos
31.1K links
Download Telegram
New post on /r/flutterdev subreddit:

About widgets and objects
import 'package:flutter/material.dart';class InputPage extends StatefulWidget {u/override_InputPageState createState() => _InputPageState();}class _InputPageState extends State<InputPage> {u/overrideWidgetbuild(BuildContext context) {return Scaffold(      appBar: AppBar(   title: Text('BMI CALCULATOR'),    ),      body: Column(       children: <Widget>[Expanded(  child: Row(children: <Widget[Expanded(child: ReusableCard( colour: Color(0xFF1D1E33), ),  ),Expande(child: ReusableCard( colour: Color(0xFF1D1E33),  ), ), ],            ),          )​class ReusableCard extends StatelessWidget {Color colour;ReusableCard({@required this.colour});u/overrideWidgetbuild(BuildContext context) {return Container(     margin: EdgeInsets.all(15),    decoration: BoxDecoration( color: colour,  borderRadius: BorderRadius.circular(10),   ),    );  }}​Hi everyone can please someone explain when I use Reusable Card and as a child in expanded(child: ReusableCard() , how does without invoking that build function the container gets returned..and we see it..? and how does that ResuableCard() becomes an object? As far as I have learned, We create object by specifying the class name(eg. class Human {String name;Human({this.name});}​andHuman jenny=Human('Jenny');print(jenny.name)​But here in the above code while in child of Expanded, we are just using ReusableCard(Colour:.....), does only right side is applied here?

May 05, 2020 at 10:44AM by milanpoudel
https://ift.tt/3aZWSN6
New post on /r/flutterdev subreddit:

Modificate conditional statement (if-else/switch-case) to make it easier to read
https://ift.tt/2xFVj9C

May 05, 2020 at 12:19PM by NimbleMouse
https://ift.tt/2W6lwaL
New post on Flutter Dev Google group:

Decoration Container
How can I make a Container, that looks like this: [image: Bildschirmfoto 2020-05-05 um 14.56.25.png]
New post on /r/flutterdev subreddit:

Super happy to find my repo "❤️Awesome Flutter ❤️ tips and tricks ❤️" trending in #1 in dart in Github. Thanks, everyone for your support, I will keep making that repo better and better.
https://ift.tt/2Sq9BSY

May 05, 2020 at 02:50PM by erluxman
https://ift.tt/35FNvkM
New post on /r/flutterdev subreddit:

<b>After one year with Flutter this is what I learned</b>
The story began with me waking up a day thinking to have a new personal project. I told myself that are a lot of successful apps out there, someones even with billions of value, so why I can’t make my own and start earning some extra cash?But I had to start with something simple to learn before launch my own “one million project”.&#8203;The best way to learn is having a real project you care forLooking for inspiration: crash courseSo I started looking for app ideas and was a surprise to found many apps that do just that: give you ideas. Some of them with a thousands of downloads and hundreds of reviews.However I couldn’t find any with a good user experience, to be more specific, all of this apps had a horrible design and were full of ads. (Seriously even the logos and graphics really sucks).This is how I decided to create <a href="https://play.google.com/store/apps/details?id=co.getboosted.emprende">my own business ideas app</a> with one focus in mind: to have the best user experience in this app category.I don’t think I hit this goal in the earlier versions. Despite the design and the navigation was better than the other apps, I wasn’t happy at all.Start from the base: A good architectureI wanted and app that not only looks good, but have also a good architecture and free of bugs, so after saw courses, read blogs and watch a bunch of Youtube videos, I opted to try a serverless approach using Firebase/Firestore as the backend.Now I won’t recommend anyone to start with Firebase, you can easily confuse Flutter features with Firebase and get lost between streams and other terms ignoring whats happening behind and how the server/api connection works.Im not saying you not to use Firebase/Firestore, but in my experience you will be more clear and having a good understanding if you start with an API and http requests at the beginning.I have to mention that Firebase offer a set of tools for free without usage limit:Firebase AnalyticsFirebase AuthFirebase Remote configFirebase Cloud MessagesCrashalyticsFirestore also have a features I like: offline content, realtime sync of the data, light speed loading, and all this for free (at least for small projects) without a server maintenance.Things I don’t like: the lack of a CMS, I don’t wanted to have a CRUD in my app so I tried some services like <a href="https://flamelink.io/">Flamelink</a> and <a href="https://www.pushtable.com/">Pushtable</a>.Also without having a good architecture you can easily pass the free usage limit. I ended paying Google $25 monthly for 4 months until I decided to move all the content to my own server/API in a shared hosting (LAMP).But thanks to this now I have a better understanding of API usage and Flutter itself.5 TakeawaysStart with a simple project. Avoid those ToDos and Chat apps. You can practice with them to know the power of Dart and Flutter, but the best way to learn is having a real project you care for.Stay away from Firebase/Firestore at the beginning, first try to learn about HTTP request and API connections using <a href="https://pub.dev/packages/http">http</a> or <a href="https://pub.dev/packages/dio">dio</a> packages. Once you feel comfortable with this, you can take all the advantages of Firebase.Read all you can about State Management. Once you have a good understanding of the Flutter native State Management, go for the approach you like more: <a href="https://www.youtube.com/watch?v=oxeYeMHVLII">BLoC</a>, <a href="https://www.youtube.com/watch?v=MkFjtCov62g">Provider</a>, <a href="https://www.youtube.com/watch?v=JsjDLHxGz4M">Scoped Model</a> or even Redux. (I personally use Provider).Pick and follow a <a href="https://medium.com/flutter-community/flutter-design-patterns-0-introduction-5e88cfff6792">Design Pattern</a>. Avoid making your project based on blocks of codes copied from Stack Overflow… like me. (<a href="https://www.youtube.com/watch?v=DO8
New tweet from FlutterDev:

📲👉🌐Embed your mobile application into a website!

Make an application on the web and share it. See how DartPad helps you test, share, and embed your code into web pages. Users can see both the code and running application.

Read more here &darr; https://t.co/hJVgER9y75— Flutter (@FlutterDev) May 5, 2020

May 05, 2020 at 05:59PM
http://twitter.com/FlutterDev/status/1257701539445043201
New post on /r/flutterdev subreddit:

COVID19 Tracker App
I developed a COVID19 Tracker app.It's a dedication for my friend who's suffering from COVID at this time :(I'm not an expert but still ;pHere's the link: https://github.com/m-hamzashakeel/Covid19-Tracker-AppDo check it out. And give the repo a start if you think it deserved :)
ThanksStay Home, Stay Safe!

May 05, 2020 at 05:38PM by m_hamzashakeel
https://ift.tt/3fpJoNU
New post on Flutter Dev Google group:

Save Variable on Disk
How can I save a variable that is exactly the same when I close the app and then open it again. So how can I save it to the disc?

May 05, 2020 at 06:40PM by Marlene Rahm
https://ift.tt/3fhGriF
New tweet from FlutterDev:

🔴LIVE: #FlutterOnlineTalks

This time, for LATAM! @fitzface will be meeting LATAM communities online, Thursday, 12pm GMT-5 (10am PDT).

Topic: Choosing Animation Widgets in Flutter.

Set a reminder to join the livestream on May 7th &rarr; https://t.co/1KZKGILmlp pic.twitter.com/YV7XeRmGdb— Flutter (@FlutterDev) May 5, 2020

May 05, 2020 at 07:58PM
http://twitter.com/FlutterDev/status/1257731437979033602
New post on Flutter Dev Google group:

Get available memory
I'm trying to find a way to get the available memory at different times in my app. I have looked a the system_info package but it states that it's not tested on both IOS and Android. Having a solid method is important for both. One developer wrote: "Unfortunately system_info doesn't support iOS

May 05, 2020 at 09:48PM by jerry hamby
https://ift.tt/35y7OQW
New post on /r/flutterdev subreddit:

Google Dev account terminated after first upload of flutter app
Hi there. Last weekend I uploaded my first flutter app (clusterup) to the Google play account for internal testing. Not an hour later my developer account (elsamuko.dev) was terminated and I don't know why.I don't know how I can test this app with friends when I can never be sure that my account is terminated. There is a lot of uncertainity now.

May 05, 2020 at 10:10PM by el_samuko
https://ift.tt/2SEhRyu
New post on Flutter Dev Google group:

[Breaking Change Proposal] Updates to the route transition record and transition delegate
Hello everyone, If you are not using the navigator page api
New post on /r/flutterdev subreddit:

Google Dev account terminated after first upload of flutter app
Hi there. Last weekend I uploaded my first flutter app (clusterup) to the Google play account for internal testing. Not an hour later my developer account (elsamuko.dev) was terminated and I don't know why.I don't know how I can test this app with friends when I can never be sure that my account is terminated. There is a lot of uncertainity now.

May 05, 2020 at 10:10PM by el_samuko
https://ift.tt/2SEhRyu
New post on Flutter Dev Google group:

ui to code
hi there ! i want to know how to create these boxes(where to do text)inside the raisedbuttons like there is this big box in the center of the interface which has those buttons and eash time i click on one of them ,a new box come out inside , please know that i am a bigginer i appreciate your help

May 06, 2020 at 04:16AM by HAMMA RAHMA
https://ift.tt/2WAdBkO
New post on /r/flutterdev subreddit:

Help Post: Simple and practical Example for Theme switching in Flutter.
So the story is :I am creating simple tips snippets every day for the last 31 days for my 100 days of Flutter tips.https://github.com/erluxman/awesomefluttertipsOn 31st day I made an example for theme switching. And I had to make a tradeoff between choosing simple native examples without third party libraries (like RxDart, Provider) or not. I tried using Inherited Widget to pass the value down the tree but we still need another way to actually change the value that will be passed down.So I opted in for Stateful widget as my thought was the theme property of Material or Cupertino App is the main player in dynamic theme. And as we usually do not observe the presence of theme variables inside Material/Cupertino App, I made this simple example.https://dartpad.dartlang.org/96008818aaabd0ede2721d6151540f84But my example was defeated or at least not clear about how to change the theme from a different widget (like setting page) as there was no slightest indication of how to access/change the theme of the app from a different widget. u/Kounex also pointed out the same issues with examples.Now what I needed help on was, as I am creating this list, I want them to be ready for run out of the box like being able to run on dartpad / codepen which do not support external libraries yet. Any simple Idea you guys have about how to implement Theme switching in simple but practical way?Thanks a lot in advance.

May 06, 2020 at 04:32AM by erluxman
https://ift.tt/2YBgFjg