You can install the demo app from here. It contain example code and a playground. This can also be used as a test suite for development of this plugin.
npm install frappe-straw
Example
import { useDocument } from 'frappe-straw';
import { type BaseDocument } from 'frappe-straw/types';
const { data, error, loading, refresh } = useDocument<BaseDocument>(
'Role',
'Guest',
{
fetchOnMount: false,
},
);