diff --git a/src/App.tsx b/src/App.tsx index 5d2d25d..35f3464 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,8 +1,8 @@ import "./App.css"; -import { RecordProvider, useNamedRecord, useRecord } from "./core/record"; +import { RecordContextProvider, useRecordContext } from "./core/record"; function Consumer({ name }: { name: string }) { - const record = useNamedRecord<{ text: string }>(name); + const record = useRecordContext<{ text: string }>(name); return (
(); + const record = useRecordContext<{ text: string }>(); return (
{

Rsbuild with React

Start building amazing things with Rsbuild.

- - + + - + - +
); };