Deploying to Firebase

Learn how to deploy a static AngularJS application to Firebase Hosting.

Weyou!

Help spread the word about this tutorial!

Firebase comes with static site hosting and a command line tool for deploying front-end applications. We'll need to install the firebase-tools npm package and compile a distribution-ready version of our application to another folder in our project.

Run npm install -g firebase-tools to install the Firebase command line tool

Run firebase login to log into your Firebase account for the CLI

Run firebase init to initialize the Firebase CLI for your project.

Select your Firebase instance for the project, and use dist as your public folder. For other prompts, the default options are OK.

Run grunt build to build a production-ready version of our application into
the dist folder

Run firebase deploy in the root of your codebase.

firebase deploy may prompt you to log in, but afterwards it should push your
application to Firebase's hosting service. Now if you visit
https://firebase-name-here.firebaseapp.com/ you should see our completed app,
ready for the world to use!