Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,13 @@ By completing the Vue.js Master Class, you will be able to land any Vue related
Convinced? [Enroll now](https://vueschool.io/the-vuejs-master-class)



## Build Setup

``` bash
# install dependencies
npm install

# if you've installed yarn instead
yarn

# serve with hot reload at localhost:8080
Expand All @@ -50,3 +52,26 @@ npm run build --report
```

For a detailed explanation on how things work, check out the [guide](http://vuejs-templates.github.io/webpack/) and [docs for vue-loader](http://vuejs.github.io/vue-loader).

## Firebase
Later master classes shou how to move past read-only, to your own writeable
database.

- Create a free account at https://firebase.google.com/
- Install firebase-cli
- Mac Homebrew: `brew install firebase-cli`
- (ToDo: community support for other OSes)
- `npm install -g firebase-tools` # optional
- Log into your Firebase account
- Create a Firebase project, as needed
- Grab the project configuration
- Click the project, to open its dashboard
- Click the ( </> ) properties icon
- Edit .env with your settings (in project root folder)
- Edit .firebaserc

`firebase login`
`npm run db:seed`

Follow steps in *Build Setup* to run / build
Your empty page awaits!
6 changes: 6 additions & 0 deletions build/setup.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
"use strict";

const fs = require('fs');
if (! fs.existsSync('.env')) {
fs.createReadStream('.env.example').pipe(fs.createWriteStream('.env'));
}
5 changes: 4 additions & 1 deletion database.rules.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
{
"rules": {
".read": true,
".write": true
".write": true,
"users": {
".indexOn": ["usernameLower", "email"]
}
}
}
9 changes: 6 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,16 @@
"dev": "node build/dev-server.js",
"start": "npm run dev",
"build": "node build/build.js",
"postinstall": "node build/setup.js",
"lint": "eslint --ext .js,.vue src",
"db:seed": "firebase database:set / src/data.json -y"
},
"dependencies": {
"@firebase/app": "^0.3.4",
"dotenv": "^5.0.1",
"firebase": "^4.12.1",
"firebase": "^5.5.8",
"moment": "^2.19.3",
"node-gyp": "^3.8.0",
"nprogress": "^0.2.0",
"vue": "^2.5.2",
"vue-router": "^3.0.1",
Expand Down Expand Up @@ -55,9 +58,9 @@
"ora": "^1.2.0",
"portfinder": "^1.0.13",
"rimraf": "^2.6.0",
"semver": "^5.3.0",
"semver": "^5.6.0",
"shelljs": "^0.7.6",
"url-loader": "^0.5.8",
"url-loader": "^1.1.2",
"vue-loader": "^13.3.0",
"vue-style-loader": "^3.0.1",
"vue-template-compiler": "^2.5.2",
Expand Down