diff options
| author | Egor Kislitsyn <egor@kislitsyn.com> | 2018-12-06 20:34:00 +0700 |
|---|---|---|
| committer | Egor Kislitsyn <egor@kislitsyn.com> | 2018-12-06 20:34:00 +0700 |
| commit | 09147cacea6b80d348d4c8364b2815d9b4cac102 (patch) | |
| tree | 55f7fda120ef527bceafb1d45844efdb46277da3 /src/boot/after_store.js | |
| parent | 3fa9b39150c318972511882239304bc08f6f57ad (diff) | |
add service worker and push notifications
Diffstat (limited to 'src/boot/after_store.js')
| -rw-r--r-- | src/boot/after_store.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/boot/after_store.js b/src/boot/after_store.js index a80baaf5..0c121fe2 100644 --- a/src/boot/after_store.js +++ b/src/boot/after_store.js @@ -17,16 +17,17 @@ import FollowRequests from '../components/follow_requests/follow_requests.vue' import OAuthCallback from '../components/oauth_callback/oauth_callback.vue' import UserSearch from '../components/user_search/user_search.vue' -const afterStoreSetup = ({store, i18n}) => { +const afterStoreSetup = ({ store, i18n }) => { window.fetch('/api/statusnet/config.json') .then((res) => res.json()) .then((data) => { - const {name, closed: registrationClosed, textlimit, server} = data.site + const { name, closed: registrationClosed, textlimit, server, vapidPublicKey } = data.site store.dispatch('setInstanceOption', { name: 'name', value: name }) store.dispatch('setInstanceOption', { name: 'registrationOpen', value: (registrationClosed === '0') }) store.dispatch('setInstanceOption', { name: 'textlimit', value: parseInt(textlimit) }) store.dispatch('setInstanceOption', { name: 'server', value: server }) + store.dispatch('setInstanceOption', { name: 'vapidPublicKey', value: vapidPublicKey }) var apiConfig = data.site.pleromafe |
