Posts

Showing posts with the label Firebase

AngularFire2 Set up

Image
In order to use Firebase as your database in Angular2 project it is essential to import AngularFire2 library to your project.For this you can refer the GitHub documentation   and get an idea. At first you have to import the library using the following code. npm install firebase angularfire2 --save Now move on to your app.module.ts file of your project and import the library. using the below code. import { AngularFirestore } from ' angularfire2/firestore ' ; And then you need to export the configuration in the same file.Use the below code to change according to your project. export const   firebaseConfig={ apikey :'', authDomain:'', databaseURL:'', storageBucket:'', messagingSenderID:'' }; Obtain the configurations according to your project through your firebase project.There you will get a similar window as below. Now import the Module using the following code. AngularFireModule.initializeApp(firebaseConfig...

How the database works in Firebase

Image
From previous articles we went through a brief introduction on Firebase. After creating the database to the project the data should be added to the database.Now connect your firebase project with your web project. Now in your firebase dashboard click the database tab.Now you will get a similar window given below. Click real time database as we are creating a realtime database.Now you will get the below window where an object of the web project is already created. Now click the the plus mark which is on the object to create a new table. Here you have given two fields on Name and value. you have to enter the name and the value.And also the Firebase database is a similar to a tree diagram where you should create your tables based on it. As an example I will create my database based on the tables given below.  Given below is my created database based on the above two tables. If you click a particular key that you have created, the link above will automati...

How to Add Firebase to your Android Project

Image
From the previous article I gave you a brief introduction on Firebase. This article will help you to know how to add Fire base to your Android project.Lets get started . Go to your firebase dashboard for the android project that we created in the last article.You would get a similar interface as below. But this may be changes with time. On the dashboard there is an option to select Add firebase to your Android app.Select it and you will get similar window as given below. Here you will be asked the Android package name which is the package name of your added Android project. Add it there. com.example.user.myandroidapp is my package name and you can get it from MainActivity.java file. Next you will be asked to fill the  Debug signing certificate SHA-1   . This is optional but it is good to add it.  To add this go to your android studio and click the button Gradle in the top right.You will get a similar window given below.Click signingReport So...

Introduction To Firebase

Image
What is Firebase? Firebase is a backend platform for building Web, Android and IOS applications. Firebase Features Real-time Database  − Firebase supports JSON data and all users connected to it receive live updates after every change. Authentication  − We can use anonymous, password or different social authentications. Hosting  − The applications can be deployed over secured connection to Firebase servers. .  Firebase is provided by Google so it is pretty much easier to use.As Firebase is a mobile platform it will you to develop apps very quickly. Lets get Started Search  Firebase  in your browser. Then you will get to many about firebase. Click  Go to Console  which in the top right. Now create a project in android studio. Visit  here  to get to know how to create an android project. You have to create a firebase project with same name of your android project. Click Add Project in the firebase view...