Skip to content
This repository was archived by the owner on Aug 16, 2022. It is now read-only.

Commit 40900d5

Browse files
revamped-v2
1 parent 9ad0680 commit 40900d5

File tree

116 files changed

+5091
-9709
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+5091
-9709
lines changed

.angular-cli.json

-60
This file was deleted.

.firebaserc

-5
This file was deleted.

.gitignore

-6
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,8 @@
22

33
# compiled output
44
/dist
5-
/dist-server
65
/tmp
76
/out-tsc
8-
src/environments
97

108
# dependencies
119
/node_modules
@@ -36,10 +34,6 @@ yarn-error.log
3634
testem.log
3735
/typings
3836

39-
# e2e
40-
/e2e/*.js
41-
/e2e/*.map
42-
4337
# System Files
4438
.DS_Store
4539
Thumbs.db

README.md

+14-108
Original file line numberDiff line numberDiff line change
@@ -1,121 +1,27 @@
1-
# Angularfire2 API Showcase
1+
# Angularfire2DemoApp
22

3-
**angularfire2** demo application showing the use cases of methods in `angularfire2/auth`, `/database` and `/firestore`, _firebase storage_
3+
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 6.0.8.
44

5+
## Development server
56

6-
## DEMO - [angularfire2 demo-app][1-link]
7+
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
78

8-
## Incomplete angularfire2-demo-app revamped [repo](https://github.com/ElecTreeFrying/demoshit), [demo](https://angularfire2-demo-app.firebaseapp.com)
9+
## Code scaffolding
910

10-
## Features
11+
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
1112

12-
* Authentication
13-
* Realtime Database
14-
* **Firestore** _(new)_
15-
* Storage
13+
## Build
1614

17-
### Authentication
15+
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.
1816

19-
[DOC|Repo][auth] / [Demo][auth-demo]
17+
## Running unit tests
2018

21-
`angularfire2/auth` API Showcase, visit the [repo][auth] for more details, **authentication** demo-app includes example code for firebase social media logins and email signin and signup and example code for managing users.
19+
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
2220

23-
* Managing users
24-
* Sign up social/email
25-
* Sign in
26-
* Sign out
21+
## Running end-to-end tests
2722

28-
### Realtime Database
23+
Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
2924

30-
[DOC|Repo][rtdb] / [Demo][rtdb-demo]
25+
## Further help
3126

32-
Covers CRUD Operations in both **List** & **Objects**
33-
34-
`angularfire2/database` API Showcase, visit the [repo][rtdb] for more details, **realtime-database** demo app includes example codes on how to write, read, update and delete documents in _**rt-db**_ using lists and objects, visit [demo-app][rtdb-demo] for more info.
35-
36-
37-
##### APIs used
38-
39-
| | Objects | Lists |
40-
|--------|-----------------------|---------------------------------------|
41-
| Create | `set()` / `update()` | `push()` |
42-
| Read | `valueChanges()` | `valueChanges()`, `snapshotChanges()` |
43-
| Update | `set()` / `update()` | `set()` / `update()` |
44-
| Delete | `remove()` | `remove()` |
45-
46-
47-
48-
### Firestore
49-
50-
[DOC|Repo][firestore] / [Demo][firestore-demo]
51-
52-
_**TODO**_
53-
54-
### Storage
55-
56-
[DOC|Repo][storage] / [Demo][storage-demo]
57-
58-
**firebase** `Storage` API Showcase, visit the [repo][storage] for more details, **firebase storage** demo app includes example codes on how to upload, download and remove files in _**Storage**_, please visit [demo-app][storage-demo] for more info.
59-
60-
* Upload files
61-
* Download files
62-
* Remove files
63-
64-
65-
## Usage
66-
67-
* `git clone https://github.com/ElecTreeFrying/angularfire2-api-showcase.git angularfire2-demo`
68-
* `cd angularfire2-demo`
69-
* `npm install`
70-
71-
Create an account [firebase console][2-link].
72-
73-
1. Select _Add Project_
74-
1. Select Authentications
75-
1. Click copy **WEB SETUP**
76-
77-
1. Create the environment files below in `src/environments/`.
78-
79-
**environment.prod.ts**
80-
81-
```
82-
export const environment = {
83-
production: true,
84-
firebaseConfig: { **WEB SETUP** }
85-
};
86-
87-
```
88-
89-
**environment.ts**
90-
91-
```
92-
export const environment = {
93-
production: false,
94-
firebaseConfig: { **WEB SETUP** }
95-
};
96-
97-
```
98-
99-
100-
101-
_**TODO**_
102-
103-
_**TODO**_
104-
105-
_**TODO**_
106-
107-
108-
[1-link]: https://workshop-demo-65669.firebaseapp.com
109-
[2-link]: https://console.firebase.google.com
110-
111-
[rtdb]: https://github.com/ElecTreeFrying/angularfire2-api-showcase/tree/master/src/app/realtime-database/realtime-database.md
112-
[rtdb-demo]: https://workshop-demo-65669.firebaseapp.com/rtdb
113-
114-
[firestore]: https://github.com/ElecTreeFrying/angularfire2-api-showcase/tree/master/src/app/firestore/firestore.md
115-
[firestore-demo]: https://workshop-demo-65669.firebaseapp.com/firestore
116-
117-
[auth]: https://github.com/ElecTreeFrying/angularfire2-api-showcase/tree/master/src/app/authentication/authentication.md
118-
[auth-demo]: https://workshop-demo-65669.firebaseapp.com/auth
119-
120-
[storage]: https://github.com/ElecTreeFrying/angularfire2-api-showcase/tree/master/src/app/storage/storage.md
121-
[storage-demo]: https://workshop-demo-65669.firebaseapp.com/storage
27+
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).

angular.json

+150
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,150 @@
1+
{
2+
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
3+
"version": 1,
4+
"newProjectRoot": "projects",
5+
"projects": {
6+
"angularfire2-demo-app": {
7+
"root": "",
8+
"sourceRoot": "src",
9+
"projectType": "application",
10+
"prefix": "app",
11+
"schematics": {
12+
"@schematics/angular:component": {
13+
"styleext": "scss",
14+
"spec": false
15+
},
16+
"@schematics/angular:class": {
17+
"spec": false
18+
},
19+
"@schematics/angular:directive": {
20+
"spec": false
21+
},
22+
"@schematics/angular:guard": {
23+
"spec": false
24+
},
25+
"@schematics/angular:module": {
26+
"spec": false
27+
},
28+
"@schematics/angular:pipe": {
29+
"spec": false
30+
},
31+
"@schematics/angular:service": {
32+
"spec": false
33+
}
34+
},
35+
"architect": {
36+
"build": {
37+
"builder": "@angular-devkit/build-angular:browser",
38+
"options": {
39+
"outputPath": "dist/angularfire2-demo-app",
40+
"index": "src/index.html",
41+
"main": "src/main.ts",
42+
"polyfills": "src/polyfills.ts",
43+
"tsConfig": "src/tsconfig.app.json",
44+
"assets": [
45+
"src/favicon.ico",
46+
"src/assets"
47+
],
48+
"styles": [
49+
"src/styles.scss"
50+
],
51+
"scripts": []
52+
},
53+
"configurations": {
54+
"production": {
55+
"fileReplacements": [
56+
{
57+
"replace": "src/environments/environment.ts",
58+
"with": "src/environments/environment.prod.ts"
59+
}
60+
],
61+
"optimization": true,
62+
"outputHashing": "all",
63+
"sourceMap": false,
64+
"extractCss": true,
65+
"namedChunks": false,
66+
"aot": true,
67+
"extractLicenses": true,
68+
"vendorChunk": false,
69+
"buildOptimizer": true
70+
}
71+
}
72+
},
73+
"serve": {
74+
"builder": "@angular-devkit/build-angular:dev-server",
75+
"options": {
76+
"browserTarget": "angularfire2-demo-app:build"
77+
},
78+
"configurations": {
79+
"production": {
80+
"browserTarget": "angularfire2-demo-app:build:production"
81+
}
82+
}
83+
},
84+
"extract-i18n": {
85+
"builder": "@angular-devkit/build-angular:extract-i18n",
86+
"options": {
87+
"browserTarget": "angularfire2-demo-app:build"
88+
}
89+
},
90+
"test": {
91+
"builder": "@angular-devkit/build-angular:karma",
92+
"options": {
93+
"main": "src/test.ts",
94+
"polyfills": "src/polyfills.ts",
95+
"tsConfig": "src/tsconfig.spec.json",
96+
"karmaConfig": "src/karma.conf.js",
97+
"styles": [
98+
"src/styles.scss"
99+
],
100+
"scripts": [],
101+
"assets": [
102+
"src/favicon.ico",
103+
"src/assets"
104+
]
105+
}
106+
},
107+
"lint": {
108+
"builder": "@angular-devkit/build-angular:tslint",
109+
"options": {
110+
"tsConfig": [
111+
"src/tsconfig.app.json",
112+
"src/tsconfig.spec.json"
113+
],
114+
"exclude": [
115+
"**/node_modules/**"
116+
]
117+
}
118+
}
119+
}
120+
},
121+
"angularfire2-demo-app-e2e": {
122+
"root": "e2e/",
123+
"projectType": "application",
124+
"architect": {
125+
"e2e": {
126+
"builder": "@angular-devkit/build-angular:protractor",
127+
"options": {
128+
"protractorConfig": "e2e/protractor.conf.js",
129+
"devServerTarget": "angularfire2-demo-app:serve"
130+
},
131+
"configurations": {
132+
"production": {
133+
"devServerTarget": "angularfire2-demo-app:serve:production"
134+
}
135+
}
136+
},
137+
"lint": {
138+
"builder": "@angular-devkit/build-angular:tslint",
139+
"options": {
140+
"tsConfig": "e2e/tsconfig.e2e.json",
141+
"exclude": [
142+
"**/node_modules/**"
143+
]
144+
}
145+
}
146+
}
147+
}
148+
},
149+
"defaultProject": "angularfire2-demo-app"
150+
}

0 commit comments

Comments
 (0)