Skip to content

Commit 1dbce63

Browse files
committed
add firebase like hosting
1 parent e50fd9e commit 1dbce63

File tree

5 files changed

+58
-2
lines changed

5 files changed

+58
-2
lines changed

.firebaserc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"projects": {
3+
"default": "todomvc-8d040"
4+
}
5+
}

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ Is the example for use Angular + Ngrx (Redux) for a [TodoMV* App](http://todomvc
44

55
You can see all files about redux in [TodoMV* App](http://todomvc.com/)
66

7-
# [DEMO ONLINE](https://dist-xwcoppfghj.now.sh)
7+
# [DEMO ONLINE](https://todomvc-8d040.firebaseapp.com/)
88

99
# Coverage 100%
1010

1111
This app is coverage in 100%
1212

13-
13+
![coverage](https://firebasestorage.googleapis.com/v0/b/todomvc-8d040.appspot.com/o/coverage.png?alt=media&token=e4e0ab21-51f3-4959-8969-381f8a081944 "coverage")
1414

1515
# Angular Info
1616

firebase-debug.log

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
[debug] [2017-09-15T05:13:26.990Z] ----------------------------------------------------------------------
2+
[debug] [2017-09-15T05:13:26.992Z] Command: /usr/local/bin/node /usr/local/bin/firebase deploy
3+
[debug] [2017-09-15T05:13:26.993Z] CLI Version: 3.9.1
4+
[debug] [2017-09-15T05:13:26.993Z] Platform: darwin
5+
[debug] [2017-09-15T05:13:26.993Z] Node Version: v7.7.2
6+
[debug] [2017-09-15T05:13:26.994Z] Time: Fri Sep 15 2017 00:13:26 GMT-0500 (-05)
7+
[debug] [2017-09-15T05:13:26.994Z] ----------------------------------------------------------------------
8+
[debug]
9+
[debug] [2017-09-15T05:13:27.008Z] > command requires scopes: ["email","openid","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","https://www.googleapis.com/auth/cloud-platform"]
10+
[debug] [2017-09-15T05:13:27.008Z] > authorizing via signed-in user
11+
[debug] [2017-09-15T05:13:27.010Z] > refreshing access token with scopes: ["email","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/cloudplatformprojects.readonly","https://www.googleapis.com/auth/firebase","openid"]
12+
[debug] [2017-09-15T05:13:27.011Z] >>> HTTP REQUEST POST https://www.googleapis.com/oauth2/v3/token { refresh_token: '1/ezlT2MpfOAffAnaE8_9bzkxcACC1CG7LLuWePSD8fzM',
13+
client_id: '563584335869-fgrhgmd47bqnekij5i8b5pr03ho849e6.apps.googleusercontent.com',
14+
client_secret: 'j9iVZfS8kkCEFUPaAeJV0sAi',
15+
grant_type: 'refresh_token',
16+
scope: 'email https://www.googleapis.com/auth/cloud-platform https://www.googleapis.com/auth/cloudplatformprojects.readonly https://www.googleapis.com/auth/firebase openid' }
17+
Fri Sep 15 2017 00:13:27 GMT-0500 (-05)
18+
[debug] [2017-09-15T05:13:27.331Z] <<< HTTP RESPONSE 200
19+
[debug] [2017-09-15T05:13:27.341Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/projects/todomvc-8d040
20+
Fri Sep 15 2017 00:13:27 GMT-0500 (-05)
21+
[debug] [2017-09-15T05:13:28.023Z] <<< HTTP RESPONSE 200
22+
[debug] [2017-09-15T05:13:28.025Z] >>> HTTP REQUEST GET https://admin.firebase.com/v1/database/todomvc-8d040/tokens
23+
Fri Sep 15 2017 00:13:28 GMT-0500 (-05)
24+
[debug] [2017-09-15T05:13:28.643Z] <<< HTTP RESPONSE 200
25+
[info]
26+
[info] === Deploying to 'todomvc-8d040'...
27+
[info]
28+
[info] i deploying hosting
29+
[info] i hosting: preparing dist directory for upload...
30+
[debug] [2017-09-15T05:13:29.805Z] >>> HTTP REQUEST PUT https://deploy.firebase.com/v1/hosting/todomvc-8d040/uploads/-Ku2xAwqs_7l0eDx1jEC?fileCount=8&message=
31+
Fri Sep 15 2017 00:13:29 GMT-0500 (-05)

firebase.json

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"hosting": {
3+
"public": "dist",
4+
"headers": [ {
5+
"source" : "**/*.@(jpg|jpeg|gif|png|js|webp|css)",
6+
"headers" : [ {
7+
"key" : "Cache-Control",
8+
"value" : "max-age=604800"
9+
} ]
10+
}, {
11+
// Sets the cache header for 404 pages to cache for 5 minutes
12+
"source" : "404.html",
13+
"headers" : [ {
14+
"key" : "Cache-Control",
15+
"value" : "max-age=2592000"
16+
} ]
17+
} ]
18+
}
19+
}

src/app/app.component.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@ <h1>todos</h1>
99
<footer class="info">
1010
<p>Double-click to edit a todo</p>
1111
<p>Written by <a href="http://twitter.com/nicobytes">Nicolas Molina</a></p>
12+
<p>Using <a href="https://angular.io/">Angular</a> and <a href="https://ngrx.github.io/">ngrx/store</a></p>
1213
<p>Part of <a href="http://todomvc.com">TodoMVC</a></p>
1314
</footer>

0 commit comments

Comments
 (0)