Webflow course card clone

This commit is contained in:
Rotimi Best
2023-09-13 06:39:46 +01:00
parent c9fa0b6098
commit ecbd75b00f
7 changed files with 64 additions and 78 deletions
@@ -1,6 +1,6 @@
import { PUBLIC_ROUTES } from '$lib/utils/constants/routes';
export default (route) => {
export default (route = '') => {
return PUBLIC_ROUTES.some((publicRoute) => {
const regex = new RegExp(publicRoute, 'g');
return regex.test(route);
@@ -0,0 +1,3 @@
export default (path: string): boolean => {
return ['login', 'signup', 'onboarding'].some((r) => path.includes(r)) || path === '';
};