feat(firebase): try firebase actions
This commit is contained in:
26
.firebase/hosting.ZGlzdC9hcHBzL2RlbW8.cache
Normal file
26
.firebase/hosting.ZGlzdC9hcHBzL2RlbW8.cache
Normal file
@@ -0,0 +1,26 @@
|
||||
index.html,1630403764380,099ee3fac125dd864e36879c8a9ae34c859a2833222ecf7da7e75469a0bd6c86
|
||||
runtime-es2015.js.map,1630403739665,a474eaf7ff39f87be2737e441a51aede2471fa9c47eb421256eb868b9f63bafe
|
||||
runtime-es5.js,1630403739673,bbb97d26905f56b2d10263b0fc474568c884cab9c2dcee356996c419c5d19c9a
|
||||
runtime-es5.js.map,1630403739673,4fc97ed988e34aa2015afb1fceda26f9586a891a80ee4b1a0e99776151af939b
|
||||
runtime-es2015.js,1630403739669,778efff3dc564fbddc7a87abf0f089c5ac0e9e31cdd79ce022dec82b1f054ab9
|
||||
assets/css/glyphicons.css,1630403764360,1ff34c9b0ce0aea2f4586fe3792329746465f417fc1f992b11e528e1fb5183c6
|
||||
assets/css/prettify-angulario.css,1630403764360,f7ccd49220579ea12997a1aa7d8d0b2909037bd5b24495210f76ba02394f7f08
|
||||
assets/css/style.css,1630403764360,55fd44c66ffc0932fc718ec21142895cb511d9fb368e05eaf0694efe8b7ed647
|
||||
assets/js/prettify.min.js,1630403764360,6e52f3166784c6f1b5476ddb0fc85369f63d9d311421716f92b110949b7e5cf7
|
||||
main-es2015.js,1630403741161,f689221c97ad505cb22783dead50baf447051aaad5e6b41750bdb41225d2b955
|
||||
main-es5.js,1630403741157,7d067afa227d37b050e5d4b84d0acc093b3d5f2f45e3bc145336ca694f0c3f3c
|
||||
assets/fonts/glyphicons-halflings-regular.eot,1630403764360,a4cb49ee9cfd245c45b704d6f1b04f0d7a924276ed4e2099664b737e5d78df30
|
||||
assets/fonts/glyphicons-halflings-regular.ttf,1630403764360,b2c9eb414ad0e9f3b46ccf9b1ca6ae0912b6e8ee75d1b81cebf21265fcfc6487
|
||||
assets/fonts/glyphicons-halflings-regular.woff,1630403764360,dd00f14e1eb1196b2d59e3e67cee55e2578bc3a03c1c5ef18e1427003d629bed
|
||||
assets/fonts/glyphicons-halflings-regular.woff2,1630403764360,e671660b60a1a7cf0cda2155eb74ab5a33c90a423142e8a1cbca286ca9babbf5
|
||||
main-es2015.js.map,1630403741157,58717d7ca314d04d20e83e1c8f485f5197358f9796990b6539e65996a6d1410f
|
||||
main-es5.js.map,1630403741153,1521549a9f5b4e941c3e1597b3e6a888923bbe240117c13e67b36cf7cb7a79a6
|
||||
polyfills-es2015.js.map,1630403739629,db127975ed302c149572d7b12401e02091c74da88903244d0c970e22ad9a3f3a
|
||||
polyfills-es2015.js,1630403739629,b9cbf7aad284ebac89392c9d4e04f21e92f82f9941be2e259c98d86168da0d9f
|
||||
assets/fonts/glyphicons-halflings-regular.svg,1630403764360,d345959a9026302c6b334384c0be26833b47e69210a0d7b702a916733cba81f3
|
||||
polyfills-es5.js,1630403742633,1fe61cfff1efd69c4aa5d9a33c6cc1aec48698fdecee0bd8bff0c094c3d51ac3
|
||||
polyfills-es5.js.map,1630403742629,0485179f2dbdfe463484b0c14f2279079726305131b6bf14428d76f4b4d9d39a
|
||||
vendor-es2015.js,1630403764336,85e9d5d93095d2f9cf91563755ad8bebe25c97f3e6778eb5fd9a6548dd44e329
|
||||
vendor-es2015.js.map,1630403764192,385a91c756383edf9ec95d87ac1d80dead2041ec6f39f0df3be4f668f65a39c4
|
||||
vendor-es5.js,1630403764096,2ffbb8e248ecef606202920064ff14e3b301bb029a7880fdca6a58c79d67463e
|
||||
vendor-es5.js.map,1630403764036,434226341b3d337f6f28c30a3d30b810f537c570147a0fe652af06f6cab0323a
|
||||
5
.firebaserc
Normal file
5
.firebaserc
Normal file
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"projects": {
|
||||
"default": "ngx-file-upload"
|
||||
}
|
||||
}
|
||||
16
.github/workflows/firebase-hosting-pull-request.yml
vendored
Normal file
16
.github/workflows/firebase-hosting-pull-request.yml
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
# This file was auto-generated by the Firebase CLI
|
||||
# https://github.com/firebase/firebase-tools
|
||||
|
||||
name: Deploy to Firebase Hosting on PR
|
||||
'on': pull_request
|
||||
jobs:
|
||||
build_and_preview:
|
||||
if: '${{ github.event.pull_request.head.repo.full_name == github.repository }}'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: FirebaseExtended/action-hosting-deploy@v0
|
||||
with:
|
||||
repoToken: '${{ secrets.GITHUB_TOKEN }}'
|
||||
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_NGX_FILE_UPLOAD }}'
|
||||
projectId: ngx-file-upload
|
||||
29
.github/workflows/on-push-or-pull.yml
vendored
29
.github/workflows/on-push-or-pull.yml
vendored
@@ -86,3 +86,32 @@ jobs:
|
||||
path: ${{ env.CACHE_NODE_MODULES_PATH }}
|
||||
key: node_modules-${{ hashFiles('**/package-lock.json') }}
|
||||
- run: npm run lint
|
||||
|
||||
# firebase preview
|
||||
build_and_preview:
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
outputs:
|
||||
output_url: ${{ steps.firebase_hosting_preview.outputs.details_url }}
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ env.CACHE_DIST_PATH }}
|
||||
key: dist-${{ github.run_id }}
|
||||
- uses: FirebaseExtended/action-hosting-deploy@v0
|
||||
continue-on-error: true
|
||||
id: firebase_hosting_preview
|
||||
with:
|
||||
repoToken: '${{ secrets.GITHUB_TOKEN }}'
|
||||
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_NGX_BOOTSTRAP_DEMO }}'
|
||||
projectId: ngx-bootstrap-demo
|
||||
channelId: ${{ env.FIREBASE_CHANNEL }}
|
||||
expires: 7d
|
||||
|
||||
# - uses: actions/checkout@v2
|
||||
# - uses: FirebaseExtended/action-hosting-deploy@v0
|
||||
# with:
|
||||
# repoToken: '${{ secrets.GITHUB_TOKEN }}'
|
||||
# firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_NGX_FILE_UPLOAD }}'
|
||||
# projectId: ngx-file-upload
|
||||
|
||||
16
firebase.json
Normal file
16
firebase.json
Normal file
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"hosting": {
|
||||
"public": "./dist/apps/demo/",
|
||||
"ignore": [
|
||||
"firebase.json",
|
||||
"**/.*",
|
||||
"**/node_modules/**"
|
||||
],
|
||||
"rewrites": [
|
||||
{
|
||||
"source": "**",
|
||||
"destination": "index.html"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
89
https:/github.com/valor-software/ng2-file-upload/index.html
Normal file
89
https:/github.com/valor-software/ng2-file-upload/index.html
Normal file
@@ -0,0 +1,89 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>Welcome to Firebase Hosting</title>
|
||||
|
||||
<!-- update the version number as needed -->
|
||||
<script defer src="/__/firebase/9.0.1/firebase-app.js"></script>
|
||||
<!-- include only the Firebase features as you need -->
|
||||
<script defer src="/__/firebase/9.0.1/firebase-auth.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-database.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-firestore.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-functions.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-messaging.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-storage.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-analytics.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-remote-config.js"></script>
|
||||
<script defer src="/__/firebase/9.0.1/firebase-performance.js"></script>
|
||||
<!--
|
||||
initialize the SDK after all desired features are loaded, set useEmulator to false
|
||||
to avoid connecting the SDK to running emulators.
|
||||
-->
|
||||
<script defer src="/__/firebase/init.js?useEmulator=true"></script>
|
||||
|
||||
<style media="screen">
|
||||
body { background: #ECEFF1; color: rgba(0,0,0,0.87); font-family: Roboto, Helvetica, Arial, sans-serif; margin: 0; padding: 0; }
|
||||
#message { background: white; max-width: 360px; margin: 100px auto 16px; padding: 32px 24px; border-radius: 3px; }
|
||||
#message h2 { color: #ffa100; font-weight: bold; font-size: 16px; margin: 0 0 8px; }
|
||||
#message h1 { font-size: 22px; font-weight: 300; color: rgba(0,0,0,0.6); margin: 0 0 16px;}
|
||||
#message p { line-height: 140%; margin: 16px 0 24px; font-size: 14px; }
|
||||
#message a { display: block; text-align: center; background: #039be5; text-transform: uppercase; text-decoration: none; color: white; padding: 16px; border-radius: 4px; }
|
||||
#message, #message a { box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24); }
|
||||
#load { color: rgba(0,0,0,0.4); text-align: center; font-size: 13px; }
|
||||
@media (max-width: 600px) {
|
||||
body, #message { margin-top: 0; background: white; box-shadow: none; }
|
||||
body { border-top: 16px solid #ffa100; }
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="message">
|
||||
<h2>Welcome</h2>
|
||||
<h1>Firebase Hosting Setup Complete</h1>
|
||||
<p>You're seeing this because you've successfully setup Firebase Hosting. Now it's time to go build something extraordinary!</p>
|
||||
<a target="_blank" href="https://firebase.google.com/docs/hosting/">Open Hosting Documentation</a>
|
||||
</div>
|
||||
<p id="load">Firebase SDK Loading…</p>
|
||||
|
||||
<script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
const loadEl = document.querySelector('#load');
|
||||
// // 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
// // The Firebase SDK is initialized and available here!
|
||||
//
|
||||
// firebase.auth().onAuthStateChanged(user => { });
|
||||
// firebase.database().ref('/path/to/ref').on('value', snapshot => { });
|
||||
// firebase.firestore().doc('/foo/bar').get().then(() => { });
|
||||
// firebase.functions().httpsCallable('yourFunction')().then(() => { });
|
||||
// firebase.messaging().requestPermission().then(() => { });
|
||||
// firebase.storage().ref('/path/to/ref').getDownloadURL().then(() => { });
|
||||
// firebase.analytics(); // call to activate
|
||||
// firebase.analytics().logEvent('tutorial_completed');
|
||||
// firebase.performance(); // call to activate
|
||||
//
|
||||
// // 🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
|
||||
|
||||
try {
|
||||
let app = firebase.app();
|
||||
let features = [
|
||||
'auth',
|
||||
'database',
|
||||
'firestore',
|
||||
'functions',
|
||||
'messaging',
|
||||
'storage',
|
||||
'analytics',
|
||||
'remoteConfig',
|
||||
'performance',
|
||||
].filter(feature => typeof app[feature] === 'function');
|
||||
loadEl.textContent = `Firebase SDK loaded with ${features.join(', ')}`;
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
loadEl.textContent = 'Error loading the Firebase SDK, check the console.';
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user