DustinBrett Upgrade to React 19, Next.js 15 & Motion 12 f19b22b· Dec 8, 2024 HistoryHistory File metadata and controls Code Blame 32 lines (25 loc) · 747 Bytes Raw import { useEffect, useRef } from "react";
import { useCallback } from 'react' import { useDispatch } from 'react-redux' import { addTag } from '../redux/actions' export const useActivateTag = () => { const dispatch = useDispatch() return useCallback( (tag: r34.AnyBiasedTag) => { dispatch(addTag(tag)) }, ...
import { render } from 'react-dom'; import { DebounceDemo } from './debounce'; import Hello from './Hello'; import './style.css'; import { Test } from './test';interface AppProps {} interface AppState { name: string; }class...
Breadcrumbs supa-blog /hooks / use-toast.tsTop File metadata and controls Code Blame 191 lines (160 loc) · 3.91 KB Raw 'use client'; // Inspired by react-hot-toast library import * as React from 'react'; import type { ToastActionElement, ToastProps } from '@/components/ui/toast'...
import { useState, useCallback } from "react"; import { ActionState, FieldErrors } from "@/lib/create-safe-action"; type Action<TInput, TOutput> = ( data: TInput ) => Promise<ActionState<TInput, TOutput>>; interface UseActionOptions<TOutput> { onSuccess?: (data: TOutput) => vo...
src-tauri src assets components hooks use-clash.ts use-listen.ts use-log-data.ts use-profiles.ts use-verge.ts use-visibility.ts locales pages polyfills services utils index.html main.tsx .editorconfig .gitignore .tool-versions CONTRIBUTING.md ...
tsconfig.node.json vite.config.ts yarn.lock Latest commit fpasquet ✨ refactoring with react and new design (#910) Mar 9, 2023 90310e6·Mar 9, 2023 History History File metadata and controls 24 lines (21 loc) · 686 Bytes Raw
Star61 Code Issues24 Pull requests20 Actions Projects Wiki Security Insights Additional navigation options Files 19c384c Sign in to see the full file tree. src/hooks useScript.ts Latest commit Cannot retrieve latest commit at this time.
import { useEffect, useState } from 'react' interface WindowSize { width: number, height: number } const useWindowSize = () => { const [size, setSize] = useState<WindowSize>({ width: document.documentElement.clientWidth, height: document.documentElement.clientHeight }) useEffect(() => { ...
*/ export function createSelectorHook( context = ReactReduxContext ): <TState = DefaultRootState, Selected = unknown>( selector: (state: TState) => Selected, equalityFn?: EqualityFn<Selected> ) => Selected { const useReduxContext = context === ReactReduxContext ? useDefaultRe...