Checking query.includes("code=") && query.includes("state=") should e part of Auth0

This example code seems like Auth0 should provide a util function since we have to look for specific query parameters whose names are set by Auth0 response. Or at least some constants. Could they ever change, it would break all code using this.
// NEW - check for the code and state parameters
const query = window.location.search;
if (query.includes(“code=”) && query.includes(“state=”)) {

// Process the login state
await auth0.handleRedirectCallback();

Hi @jcl,

Welcome to the Community!

Could you add this with more information about the situation as an issue to the github repo?

Thanks,
Dan

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.