• This repository has been archived on 20/Apr/2021
  • Stars
    star
    103
  • Rank 333,046 (Top 7 %)
  • Language Vue
  • Created over 6 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Run the Nuxt.js application (SPA * SSR * PWA) on Firebase.

nuxt-firebase-pwa

Nuxt.js * Firebase = SPA * SSR * PWA * Serverless

DEMO

πŸ‘»Description

Run the Nuxt.js application on Firebase.

Features

  • SPA (Single Page Application)
  • SSR (Sever Side Rendering)
  • PWA (Progressive Web Apps)
  • Serverless (Cloud Functions for Firebase + Firebase Hosting)

Libraries

πŸ‘ΆStart

Install dependencies

$ npm install # Or yarn install
$ cd /path/to/nuxt-firebase-pwa/src && npm install
$ cd /path/to/nuxt-firebase-pwa/functions && npm install

Launch development server

$ cd /path/to/nuxt-firebase-pwa/src
$ npm run dev

Open http://localhost:3000

πŸš€Build and Deploy to Firebase

Build

Build Nuxt.js app.

$ cd /path/to/nuxt-firebase-pwa/src
$ npm run build

Copy assets and static files.

$ cd /path/to/nuxt-firebase-pwa
$ npm run setup

Firebase Project Setup

Create a Firebase Project using the Firebase Console.

Install Firebase CLI.

$ npm install -g firebase-tools
$ exec $SHELL -l

Login to Firebase.

$ firebase login

Edit .firebaserc

{
  "projects": {
    "default": "<your-firebase-project-id>"
  }
}

Emulate Firebase on local

$ npm run serve

Open http://localhost:5000

DeployπŸŽ‰

$ npm run deploy

Let's enjoy!!!