mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-05 16:23:36 +00:00
11 lines
297 B
TypeScript
11 lines
297 B
TypeScript
import { useContext } from 'react';
|
|
import { GitSyncContext } from '@/contexts/GitSyncContext';
|
|
|
|
export function useGitSyncState() {
|
|
const context = useContext(GitSyncContext);
|
|
if (!context) {
|
|
throw new Error('useGitSyncState must be used within GitSyncProvider');
|
|
}
|
|
return context;
|
|
}
|