dhatguy
06/11/2022, 1:17 PMasync function doesSessionExist() {
if (await SuperTokens.doesSessionExist()) {
// user is logged in
console.log("there is a session");
} else {
// user has not logged in yet
}
}
this returns error in react nativedhatguy
06/11/2022, 1:18 PMrp_st
06/11/2022, 1:30 PMdhatguy
06/11/2022, 1:30 PMimport SuperTokens from 'supertokens-react-native';
rp_st
06/11/2022, 1:31 PMrp_st
06/11/2022, 1:31 PMnkshah2
06/11/2022, 1:32 PMdhatguy
06/11/2022, 1:33 PMimport SuperTokens from "supertokens-react-native";
const apiDomain = "http://192.168.43.75:7000"; // TODO: change url to your own IP address
SuperTokens.init({
apiDomain,
apiBasePath: "/api/auth",
});
dhatguy
06/11/2022, 1:34 PMnkshah2
06/11/2022, 1:34 PMnkshah2
06/11/2022, 1:35 PMdhatguy
06/11/2022, 1:43 PMnkshah2
06/11/2022, 1:44 PMnkshah2
06/11/2022, 1:44 PMnkshah2
06/11/2022, 1:44 PMdhatguy
06/11/2022, 1:46 PMnkshah2
06/11/2022, 1:53 PMdhatguy
06/11/2022, 1:58 PMdhatguy
06/11/2022, 1:58 PMnkshah2
06/11/2022, 2:11 PMdhatguy
06/11/2022, 2:43 PMdhatguy
06/11/2022, 2:43 PMrp_st
06/11/2022, 2:59 PMdhatguy
06/11/2022, 3:14 PMrp_st
06/11/2022, 3:15 PMdhatguy
06/11/2022, 3:16 PMappInfo: {
appName: "nsm",
apiDomain: "http://localhost:7000",
websiteDomain: "http://localhost:3000",
apiBasePath: "/api/auth",
websiteBasePath: "/api/auth",
}
rp_st
06/11/2022, 3:16 PMdhatguy
06/11/2022, 3:16 PMSession.init({})
dhatguy
06/11/2022, 3:17 PMdhatguy
06/11/2022, 3:17 PMrp_st
06/11/2022, 3:17 PMrp_st
06/11/2022, 3:22 PMrp_st
06/11/2022, 3:23 PMrp_st
06/11/2022, 3:23 PMdhatguy
06/11/2022, 3:31 PMdhatguy
06/11/2022, 3:31 PMrp_st
06/11/2022, 3:33 PM