Sign in

Flutter Developer | Mobile App Developer | Node.JS | Self-Learner

GetX is one of the various ways of managing state in Flutter. Getx is the simplest and easiest way of managing state as it uses inline code or less code for managing state.

Let’s first talk about what actually state management is and then we’ll talk about various state management ways.
State Management: It is like sharing state or data with other screens in the project. When there is change in state in one screen and have to use that updated state in other screen ,there comes a term “State Management”.

List of State Management Ways:
1. GetX
2. Provider
2. Redux
4…


In application, there comes a point where we need to integrate push notification.Though we integrate it successfully, sometime we got issue or app got crashed while sending push notifications while app in not running or is opened in background.So here we will integrate push notification using firebase in flutter which works in all states:foreground,background and even when app is closed(not running).Moreover, if you want to redirect that notification to the certain page in the application after click on push notification,here is link.

Let’s start:)

Firebase and push notification setup

Step I

  • Create firebase project for your app and add googleservices.json


From the previous article, you’ll learn how to show push notification in foreground and in background in flutter via firebase. Only showing push notification is not enough. We need to redirect it to certain screen after tapping on it.So the question arise:How do we redirect to certain screen on tapping push notification in flutter.

Here we go:

Prerequisite:
- If you know ,integrate Push notification in flutter yourself
- If not, follow this article about how to add Push Notification In Flutter in Background as well as in Foreground Using Firebase

Procedure(Redirect to certain screen on tapping notification):

In the…


Do you want to integrate digital payment method “KHALTI” in flutter?If your answer is yes then this is the right place you are now.So without wasting time,let’s start integrating khalti in Flutter apps.


You’ll get to know about how to use phone authentication using firebase in flutter. I’ll show you how to do phone auth in flutter project like whatsapp, viber and imo. If you are not registered then it will redirect to the register screen and if you are a registered user then it will redirect to homepage.


I will show how to customize google map marker icon by putting the image of your choice in Flutter. I won’t discuss about the google map integration in flutter cause this article will be long if I do so. So for that I will write another one. But for now I will show you how change google map marker icon. Here we go:

Prerequisite:

  • Google map must be integrated in your flutter project.
  • Wherever you use marker like:
Marker demo= new Marker(
markerId: MarkerId(“marker_id”),
infoWindow: InfoWindow(title:_currentAddress),
);

There come a red default red marker on the google map


Http Status codes are the part of HTTP. These codes are returned by the server when you made request to the server. These status codes are mainly categorized into 5 category. The first digit of the status code defines the class of response, while the last two digits do not have any classifying or categorization role. There are five classes defined by the standard like in the picture above.
1xx : Informational Responses; the request was received, continuing process
2xx: Successful Responses; the action requested by the client was received, understood, and accepted
3xx: Redirects; the client must take additional…


In most cases, there is requirement of SHA-1 key like in firebase and signing processes and in google apis. So the question arise what’s exactly is this and how do we generate this?
Here we go

What is SHA-1 key?

SHA-1 (Secure Hash Algorithm) 1 fingerprint is a unique key generated for your PC that can be used for signing. Its mainly used for submitting for using the Google APIs(In case of Android).It is also requires in firebase also.


After making a complete app in Flutter, we all want to upload it to play store. But the thing is, when we build apk initially that one is debug apk by default not the release apk. While publishing app to playstore we need release apk and the procedure to make release apk are:

Create .jks File

👉Step I
At first we need to create keystore file which is of .jks format. So for this, we’ll run the below code in terminal:

//For windows:
keytool -genkey -v -keystore Part1 -storetype JKS -keyalg RSA -keysize 2048 -validity 10000 -alias PART2

PART1 means put the location…


In flutter, let's have a long list of length 100 or 1000 and have to start it from 50 or 60 position then how would you start?🤔🤔🤔
If you get answer then that’s really great but if you did not get then once look below and read.
Suppose you have a list 10 items like:

List<int> _list =[2,6,4,9,98,34,12,100,23,79];

And you have to show data from the 5th position.(Use sublist())
For this we’ll do like:

print(_list.sublist(4)); //put one value less than desired position
//output: [98,34,12,100,23,79]

And if you like to print only first 5 items then you’ll have to use take() like this:

print(_list.take(5));
//output:[2,6,4,9,98]

Hence, using sublist() , you’ll start the list from ith position and using take(),
you’ll only get the first ith items of list.

Keep Coding and keep Learning
Thanks

Lakshydeep Vikram

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store