![]()
Get your point. Iโm always thinking of as less friction as possible when dealing with an UX (not the same as when you type an answer: your mind works in a different way even if answering is more complex).
Great. Will however try migrate ASAP. Right now
const identityProvider = (ENV as any).II_URL
? String((ENV as any).II_URL)
: "https://identity.ic0.app/#authorize";
so I guess this changes to https://id.ai (presume the authentication handshake is now handled directly) hence
async function loginWithII(authClient: AuthClient): Promise<void> {
const derivationOrigin =
(ENV as any).DERIVATION_ORIGIN && String((ENV as any).DERIVATION_ORIGIN).length > 0
? String((ENV as any).DERIVATION_ORIGIN)
: undefined;
const identityProvider = (ENV as any).II_URL
? String((ENV as any).II_URL)
: "https://id.ai";
await new Promise<void>((resolve, reject) => {
authClient.login({
identityProvider,
derivationOrigin,
maxTimeToLive: DELEGATION_MAX_TTL_NS,
onSuccess: () => resolve(),
onError: (err) => reject(err),
});
});
}
While also at env level implement
export const ENV: ICPPEnv = {
HOST: โhttps://ic0.appโ,
NETWORK: โicโ,
II_URL: โhttps://id.aiโ,
DERIVATION_ORIGIN: โhttps://tuaah-oaaaa-aaaai-atxxx-yyy.icp0.ioโ,
}