Explicit state and event id minification

BE
18h ago
+7415-236

Summary

Add state and event name minification with CLI management tools.

  • Introduces minify.json config file to map state/event names to short IDs (e.g., myapp.state.AppState → "a")
  • Adds reflex minify CLI command group for managing minification
  • Reduces frontend bundle size and WebSocket payload size by replacing long state/event paths with compact identifiers

CLI Commands

# Initialize minify.json with IDs for all states and events
reflex minify init

# Sync minify.json after code changes
reflex minify sync
reflex minify sync --prune --reassign-deleted

# Validate config against current codebase
reflex minify validate

# List state tree with minified names
reflex minify list
reflex minify list --json

# Lookup a minified path
reflex minify lookup "a.bU"

based on #6098