tailwind-rs-scanner 0.15.4

Advanced content scanning for Tailwind-RS Core
Documentation

tailwind-rs-scanner

Advanced content scanning for Tailwind-RS Core, providing intelligent class detection and extraction from source files.

This crate provides comprehensive content scanning capabilities:

  • Multi-language support (Rust, JavaScript, TypeScript, HTML, etc.)
  • Parallel file processing for performance
  • Intelligent class extraction with context awareness
  • File watching and incremental updates
  • Tree-sitter integration for accurate parsing

Features

  • Multi-Language Support: Rust, JS/TS, HTML, Vue, Svelte, and more
  • Parallel Processing: Multi-threaded file scanning for speed
  • Intelligent Extraction: Context-aware class detection
  • File Watching: Real-time file change detection
  • Tree-sitter Integration: Accurate AST-based parsing
  • Performance: Optimized for large codebases

Example

use tailwind_rs_scanner::*;

#[tokio::main]
async fn main() -> Result<(), ScannerError> {
    let scanner = ContentScanner::new(ScanConfig::default())?;
    
    let classes = scanner.scan_for_classes().await?;
    println!("Found {} classes", classes.total_classes());
    
    // Watch for changes
    let mut watcher = scanner.watch().await?;
    while let Some(update) = watcher.next().await {
        println!("Classes updated: {:?}", update);
    }
    
    Ok(())
}