Search documentation of phoenix_kit

# mix phoenix_kit.modernize_layouts (phoenix_kit v1.6.19)

View Source

Modernizes PhoenixKit layout integration for Phoenix v1.8+ compatibility.

This task performs automatic migration of existing PhoenixKit installations to support both Phoenix v1.7- and v1.8+ layout systems seamlessly.

## What it does

1. Detects Phoenix version - Automatically detects your Phoenix version
2. Updates configuration - Modernizes layout configuration in config.exs
3. Migrates templates - Updates any existing PhoenixKit templates
4. Adds LayoutWrapper - Ensures LayoutWrapper component is available
5. Validates compatibility - Tests the new setup

## Usage

    mix phoenix_kit.modernize_layouts

## Options

    --dry-run         Show what would be changed without making changes
    --force           Force migration even if already modernized
    --verbose         Show detailed output during migration
    --backup          Create backup of modified files
    --skip-templates  Skip template migration (config only)

## Examples

    # Standard migration with backup
    mix phoenix_kit.modernize_layouts --backup

    # See what would be changed without modifying files
    mix phoenix_kit.modernize_layouts --dry-run

    # Force re-migration with detailed output
    mix phoenix_kit.modernize_layouts --force --verbose

The migration is idempotent - safe to run multiple times.