Skip to content

Instantly share code, notes, and snippets.

View jerrywonderr's full-sized avatar

Jerry Wonder jerrywonderr

View GitHub Profile
@jerrywonderr
jerrywonderr / index.tsx
Created December 24, 2023 15:02
Qoreid Implementation
/* eslint-disable react-native/no-inline-styles */
import React, { FC } from "react"
import { WebView } from "react-native-webview"
import { View } from "native-base"
export const KYC: FC<any> = ({ navigation }) => {
const remoteScriptUrl = "https://dashboard.qoreid.com/qoreid-sdk/qoreid.js"
// Use the injectedJavaScriptBeforeContentLoaded to load the script
@jerrywonderr
jerrywonderr / middleware.ts
Created February 15, 2024 16:11
Next Auth Implementation using Middlewares
import { NextResponse } from 'next/server'
import type { NextRequest } from 'next/server'
import { supabaseClient } from '../supabase'
export const config = {
matcher: ['/auth/routes/:function*'],
}
const loginUrl = new URL('/login', request.url)
// Add ?from=/incoming-url to the /login URL
loginUrl.searchParams.set('from', request.nextUrl.pathname)