This commit is contained in:
parent
abb82a3189
commit
d1f23fa38d
3 changed files with 17 additions and 0 deletions
|
@ -38,6 +38,11 @@ module.exports = {
|
|||
assetsSubDirectory: 'static',
|
||||
assetsPublicPath: '/',
|
||||
proxyTable: {
|
||||
'/manifest.json': {
|
||||
target,
|
||||
changeOrigin: true,
|
||||
cookieDomainRewrite: 'localhost'
|
||||
},
|
||||
'/api': {
|
||||
target,
|
||||
changeOrigin: true,
|
||||
|
|
|
@ -73,6 +73,7 @@
|
|||
|
||||
.search-bar-input {
|
||||
flex: 1 0 auto;
|
||||
margin-left: 0.5em;
|
||||
}
|
||||
|
||||
.cancel-search {
|
||||
|
|
11
src/main.js
11
src/main.js
|
@ -53,6 +53,17 @@ const persistedStateOptions = {
|
|||
};
|
||||
|
||||
(async () => {
|
||||
if ('serviceWorker' in navigator) {
|
||||
// declaring scope manually
|
||||
navigator.serviceWorker.register('/sw-pleroma.js', {scope: '/'}).then((registration) => {
|
||||
console.log('Service worker registration succeeded:', registration);
|
||||
}, /*catch*/ (error) => {
|
||||
console.error(`Service worker registration failed: ${error}`);
|
||||
});
|
||||
} else {
|
||||
console.error('Service workers are not supported.');
|
||||
}
|
||||
|
||||
let storageError = false
|
||||
const plugins = [pushNotifications]
|
||||
try {
|
||||
|
|
Loading…
Reference in a new issue