Moved code into src folder. Added build for component library.

This commit is contained in:
Mike Cao 2023-08-21 02:06:09 -07:00
parent 7a7233ead4
commit ede658771e
490 changed files with 749 additions and 442 deletions

19
src/pages/sso.js Normal file
View file

@ -0,0 +1,19 @@
import { useEffect } from 'react';
import { Loading } from 'react-basics';
import { useRouter } from 'next/router';
import { setClientAuthToken } from 'lib/client';
export default function () {
const router = useRouter();
const { token, url } = router.query;
useEffect(() => {
if (url && token) {
setClientAuthToken(token);
router.push(url);
}
}, [router, url, token]);
return <Loading size="xl" />;
}