()
| 57 | } |
| 58 | |
| 59 | export function createDrawContext() { |
| 60 | const context = getContext(DrawContext) |
| 61 | |
| 62 | if (context === undefined) { |
| 63 | throw new Error( |
| 64 | `createDrawContext must be used within a DrawClientProvider`, |
| 65 | ) |
| 66 | } |
| 67 | |
| 68 | return context |
| 69 | } |
no test coverage detected