Disable service worker (#63)

Service has caused some bugs where
the trust domains were ignored
and api calls were done without proper credentials
This commit is contained in:
Maycon Santos
2022-08-03 09:44:46 +02:00
committed by GitHub
parent 321e4d8311
commit d71d8214e7
2 changed files with 4 additions and 3 deletions

View File

@@ -47,8 +47,8 @@
"scripts": { "scripts": {
"copy": "copyfiles -f ./node_modules/@axa-fr/react-oidc/dist/OidcServiceWorker.js ./public", "copy": "copyfiles -f ./node_modules/@axa-fr/react-oidc/dist/OidcServiceWorker.js ./public",
"copytrusted": "copyfiles -f ./public/local/OidcTrustedDomains.js ./public", "copytrusted": "copyfiles -f ./public/local/OidcTrustedDomains.js ./public",
"start": "npm run copy && npm run copytrusted && react-scripts start", "start": "react-scripts start",
"build": "npm run copy && react-scripts build", "build": "react-scripts build",
"test": "react-scripts test", "test": "react-scripts test",
"eject": "react-scripts eject" "eject": "react-scripts eject"
}, },

View File

@@ -20,7 +20,8 @@ const providerConfig = {
refresh_time_before_tokens_expiration_in_second: 30, refresh_time_before_tokens_expiration_in_second: 30,
silent_redirect_uri: window.location.origin + '#silent-callback', silent_redirect_uri: window.location.origin + '#silent-callback',
scope: 'openid profile email api offline_access email_verified', scope: 'openid profile email api offline_access email_verified',
service_worker_relative_url:'/OidcServiceWorker.js', // disabling service worker
// service_worker_relative_url:'/OidcServiceWorker.js',
service_worker_only: false, service_worker_only: false,
authority_configuration: { authority_configuration: {
authorization_endpoint: authority + "/authorize", authorization_endpoint: authority + "/authorize",