Core Utilities & Diagnostics
Low-level functions like resolveDriveImage, analyzeDriveUrl, and smart prefetch.
Overview
DriveLoader exports its internal diagnostic tools. Use analyzeDriveUrl() to classify links and get format warnings.
Code Example
utilities.tsx
| 1 | import { analyzeDriveUrl, prefetchAudio } from '@driveloader/react'; |
| 2 | |
| 3 | const diag = analyzeDriveUrl(url); |
| 4 | await prefetchAudio(url); |
Best Practices
- •Prefetch heavy assets (like videos or high-res images) on hover to eliminate loading spinners on click.
