Files
rspade_system/app/RSpade/resource/vscode_extension
root 77b4d10af8 Refactor filename naming system and apply convention-based renames
Standardize settings file naming and relocate documentation files
Fix code quality violations from rsx:check
Reorganize user_management directory into logical subdirectories
Move Quill Bundle to core and align with Tom Select pattern
Simplify Site Settings page to focus on core site information
Complete Phase 5: Multi-tenant authentication with login flow and site selection
Add route query parameter rule and synchronize filename validation logic
Fix critical bug in UpdateNpmCommand causing missing JavaScript stubs
Implement filename convention rule and resolve VS Code auto-rename conflict
Implement js-sanitizer RPC server to eliminate 900+ Node.js process spawns
Implement RPC server architecture for JavaScript parsing
WIP: Add RPC server infrastructure for JS parsing (partial implementation)
Update jqhtml terminology from destroy to stop, fix datagrid DOM preservation
Add JQHTML-CLASS-01 rule and fix redundant class names
Improve code quality rules and resolve violations
Remove legacy fatal error format in favor of unified 'fatal' error type
Filter internal keys from window.rsxapp output
Update button styling and comprehensive form/modal documentation
Add conditional fly-in animation for modals
Fix non-deterministic bundle compilation

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-13 19:10:02 +00:00
..

RSpade VS Code Extension

Overview

The RSpade VS Code extension provides development tools and enhancements specifically for RSpade framework projects.

Features

RSX:USE Section Management

  • Automatically highlights RSX:USE sections in gray
  • Shows info icons to indicate auto-generated code
  • Prevents accidental editing of managed sections

Smart File Operations

  • Automatically updates PHP namespaces when files are moved
  • Maintains RSX class references during refactoring
  • Updates use statements as needed

PHP Formatting Integration

  • Uses the main formatter at ./bin/rsx-format
  • Handles PHP and JSON file formatting
  • Preserves file modification times to prevent VS Code conflicts
  • Formats on save via RunOnSave extension (configured in settings.json)

LLMDIRECTIVE Folding

  • Automatically collapses LLMDIRECTIVE comment blocks
  • Reduces visual clutter in code
  • Preserves directives for AI assistants

Installation

Automatic Installation

The extension auto-installs when you open a terminal in VS Code if:

  • The project has "rspade.projectType": "rspade" in .vscode/settings.json
  • Auto-install is enabled in settings

Manual Installation

# From the extension directory
./build.sh
code --install-extension rspade-framework.vsix

Building the Extension

cd /app/RSpade/Extension
./build.sh

The build script:

  • Auto-increments version number
  • Compiles TypeScript to JavaScript
  • Packages as rspade-framework.vsix
  • Runs inside Docker for consistency

Configuration

Add to .vscode/settings.json:

{
    "rspade.projectType": "rspade",
    "rspade.autoCheckExtension": true,
    "rspade.autoInstallExtension": true
}

Setup Scripts

Located in .vscode/ide_setup/:

Unix/Linux/macOS: check_setup.sh

  • Checks for Python, PHP, Node.js dependencies
  • Verifies npm packages
  • Checks extension status
  • Auto-installs updates if configured

Windows: check_setup.ps1

  • PowerShell equivalent of Unix script
  • Uses Chocolatey for package management
  • Same functionality as Unix version

Development

Source Structure

src/
├── extension.ts         - Main extension entry
├── folding_provider.ts  - LLMDIRECTIVE folding
├── decoration_provider.ts - RSX:USE highlighting
├── file_watcher.ts      - File operation handling
└── formatting_provider.ts - PHP formatting integration

Testing

The extension is tested with:

  • Manual testing in VS Code
  • Integration with formatter tests
  • File operation scenarios

Troubleshooting

Extension Not Loading

  • Check "rspade.projectType": "rspade" in settings
  • Verify extension is installed: code --list-extensions | grep rspade
  • Check VS Code developer console for errors

Formatting Issues

  • The main formatter is now at: ./bin/rsx-format
  • For PHP files: ./bin/formatters/php-formatter
  • For JSON files: ./bin/formatters/json-formatter
  • Check IDE setup: .vscode/ide_setup/check_setup.sh
  • Verify PHP is in PATH