Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.

Commit

Permalink
feat: use updated config
Browse files Browse the repository at this point in the history
Signed-off-by: Mike Murray <hellomikemurray@gmail.com>
  • Loading branch information
mikemurray committed Mar 31, 2020
1 parent 065d50d commit 878ca26
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions package/src/lib/core/reaction.js
Expand Up @@ -11,17 +11,26 @@ import { plugins } from "./plugins";
*/
export function Reaction(props) {
const {
graphqlApiUrl,
oidcClientId,
oidcUrl,
rootUrl,
config: {
PUBLIC_GRAPHQL_API_URL,
PUBLIC_OIDC_CLIENT_ID,
PUBLIC_OIDC_URL,
PUBLIC_ROOT_URL
},
AppComponent,
DashboardComponent,
dashboardComponentProps
} = props;

const apolloClient = initApollo({ graphqlApiUrl });
const authenticationProviderProps = getOidcProps({ oidcClientId, oidcUrl, rootUrl });
// Initialize apollo client to be used for the ApolloProvider in the AppComponent
const apolloClient = initApollo({ graphqlApiUrl: PUBLIC_GRAPHQL_API_URL });

// Create OIDC props to be used on the AuthenticationProvider in the AppComponent
const authenticationProviderProps = getOidcProps({
oidcClientId: PUBLIC_OIDC_CLIENT_ID,
oidcUrl: PUBLIC_OIDC_URL,
rootUrl: PUBLIC_ROOT_URL
});

ReactDOM.render(
(
Expand Down

0 comments on commit 878ca26

Please sign in to comment.