Skip to content

Add missing imports in examples#484

Merged
MiloszFilimowski merged 1 commit intomainfrom
fix-two-slash
Feb 26, 2026
Merged

Add missing imports in examples#484
MiloszFilimowski merged 1 commit intomainfrom
fix-two-slash

Conversation

@MiloszFilimowski
Copy link
Collaborator

Description

  • Add // ---cut--- twoslash directives with import statements to @example JSDoc blocks in usePermissions.ts so twoslash can resolve useCameraPermissions / useMicrophonePermissions during typedoc builds

Motivation and Context

The example code samples referenced exported hooks without importing them, causing twoslash compilation failures when typedoc generates API docs.

Documentation impact

  • Documentation update required
  • Documentation updated in another PR
  • No documentation update required

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to
    not work as expected)

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds twoslash directives with import statements to JSDoc @example blocks in the usePermissions.ts file to fix typedoc build failures. The examples previously referenced exported hooks without importing them, which caused twoslash compilation errors during API documentation generation.

Changes:

  • Added import statements and // ---cut--- twoslash directives to two JSDoc @example blocks for useCameraPermissions and useMicrophonePermissions hooks

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@MiloszFilimowski MiloszFilimowski merged commit 473ba1d into main Feb 26, 2026
6 checks passed
@MiloszFilimowski MiloszFilimowski deleted the fix-two-slash branch February 26, 2026 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants