Last active
August 28, 2018 08:05
-
-
Save eyeccc/c39e2f31131b43dbef2a2a664cfd5119 to your computer and use it in GitHub Desktop.
This file contains 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
type keycloak; | |
type init; | |
type initParam; | |
[@bs.module] external keycloak : string => keycloak = "keycloak-js"; | |
[@bs.obj] external makeInitParam : (~onLoad: string, unit) => initParam = ""; | |
[@bs.send] external init : (keycloak, initParam) => Js.Promise.t(bool) = ""; | |
let myConfig = "./keycloakConfig.json"; | |
let auth = myConfig |> keycloak |. init(makeInitParam(~onLoad="login-required", ()))); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment