This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const copyToClipboard = str => { | |
| const el = document.createElement('textarea'); | |
| el.value = str; | |
| el.setAttribute('readonly', ''); | |
| el.style.position = 'absolute'; | |
| el.style.left = '-9999px'; | |
| document.body.appendChild(el); | |
| el.select(); | |
| document.execCommand('copy'); | |
| document.body.removeChild(el); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| How can we read all data from a firestore collection? | |
| HI guys I want to show you how. | |
| I had these problems for reading all data from a firestore collection: | |
| 1. firestore cursor is not proper as a powerful cursor as to be able make this task done. | |
| 2. after few thousands request you will get Bandwidth Exhausted error. | |
| For doing this task we need two things and each one can helps us resolve above problems: | |
| 1. A powerfull cursor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Vue.prototype.$forceCompute= function(computedName, forceUpdate /* default: true */) { | |
| if (this._computedWatchers[computedName]) { | |
| this._computedWatchers[computedName].run(); | |
| if (forceUpdate || typeof forceUpdate == 'undefined') this.$forceUpdate() | |
| } | |
| } | |
| this.$forceCompute('title') | |
| this.$forceCompute('title', false) // No force update |
OlderNewer