Skip to main content

How To Set Up Android Studio/VS Code For Flutter 2021 (Complete Guide) In Ubuntu | Step By Step Tutorial

In this post, we're going to set up the android studio for flutter - Google’s most awaited UI tool kit for building beautiful, natively compiled applications for mobile, web, and desktop from a single codebase. 

So a single codebase for making an application for multiple platforms.



Step 1:
Download flutter SDK from flutter.dev and after extracting it place the flutter folder inside it at your desired location like this:-


Step 2:
Open the terminal and Set the path up to the bin folder inside flutter:- 

export PATH=$PATH:/home/himanshu/Desktop/fluttersdk/flutter/bin


Step 3:
Download java 8 and set JAVA_HOME and JRE_HOME path.

Run this command in terminal:-

sudo apt install openjdk-8-jdk openjdk-8-jre

It will download the java 8 package in /usr/lib/jvm/ and now set the JAVA_HOME and JRE_HOME path up to this location for this,

Run this command in the terminal:-

export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
export JRE_HOME=/usr/lib/jvm/java-8-openjdk-amd64/jre



Step 4:
Install flutter and dart plugin in the android studio.

Open android studio and Go to File ->Settings -> Plugins -> Marketplace.

Search flutter and click on install also click yes in order to install the dart plugin.

Step 5:
Go to Plugins -> Installed.

Enable all the plugins in the list i.e all the checkboxes must be checked.


Now, Restart Android Studio.

You can start making flutter projects.


Step 6 (VS Code):
Open visual studio code -> Go to Extensions and search flutter and click install this also installs the required Dart plugin.


Go to View->Command Palette and type flutter and select Flutter: New Project.


Now click on set up the path for flutter SDK and go to the flutter folder and press enter.

Now, Enter a project name, such as hello_world, and press Enter.

Now you are ready to make your flutter applications.

If you face any problem or have any suggestion please comment it down we love to answer it.

Comment down what next topic you need a guide on? or Drop a message on our social media handle
 



Comments

Popular posts from this blog

Face Recognition Using Firebase ML Kit In Android Studio 2020 (Complete Guide) | Step By Step Tutorial

Today, in this post we are going to make an android app that recognizes facial features from an image using a firebase ml kit in the android studio.                                                      After doing all the steps the output will look like this: Step 1: Add Firebase to your android project: I recommend you to see  how to add firebase to the android project in 5minutes  to know how to add it or if you already add it then you can move on to 2nd Step.      Step 2:  Add this dependency for the ml kit android libraries to your app-level build.gradle file:   implementation 'com.google.firebase:firebase-ml-vision:24.0.1'   // If you want to detect face contours (landmark detection and classification   // don't require this additional model):   implementation 'com.google.firebase:...

Select (or Capture) and Crop Image In Android Studio 2020 (Complete Guide) | Step By Step Guide

In, this post we're going to make an app that captures or selects an image and then displays in an image view using a third party library - android image cropper by ArthurHub at Github. Step 1: Add Dependency : Open android studio and paste this dependency in app-level build.gradle file as shown below: implementation 'com.theartofdev.edmodo:android-image-cropper:2.7.+' and then click on Sync Now. Step 2: Design the main activity layout : Add a Button and an ImageView to select and display image respectively as shown below: Step 3: Modify AndroidMainfest.xml by adding the CropImageActivity : <activity android:name="com.theartofdev.edmodo.cropper.CropImageActivity" android:screenOrientation="portrait" android:theme="@style/Base.Theme.AppCompat"/>  as shown below- Step 4: Open CropImageActivity on Click of a button : Step 5: Lastly, override the On Activity Result and update ImageView : ...

Detect and Track Object Using Firebase ML Kit In Android Studio 2020(Complete Guide) With Source Code | Step By Step Tutorial

In this post, we're going to detect and track an object in an image using a firebase ml kit in an android studio. This is the output after doing all the steps: So, now make it happen: Step 1: Add Firebase to your android project: I recommend you to see  how to add firebase to the android project in 5minutes  to know how to add it or if you already add it then you can move on to 2nd Step.  Step 2: Add this dependency for the ml kit android libraries to your app-level build.gradle file: implementation 'com.google.firebase:firebase-ml-vision:24.0.1' implementation 'com.google.firebase:firebase-ml-vision-object-detection-model:19.0.3' as shown below and then click on Sync Now. Step 3: Design the layout of the activity: <? xml version ="1.0" encoding ="utf-8" ?> <RelativeLayout xmlns: android ="http://schemas.android.com/apk/res/android" android :layout_width ="match_parent" android :la...



DMCA.com Protection Status

Copywrite © 2021 The MindfulCode