Skip to content

v1.0.0

Latest

Choose a tag to compare

@github-actions github-actions released this 07 Aug 13:18

   🚨 Breaking Changes

  • Use shorter k: syntax  -  by arnoson (650c7)
    View changes on GitHub

Migration

Snippets

Change prefix from snippet to k.
Example: <snippet:menu><k:menu>

Slots

Change prefix from slot to k:slot. For named slots, move the slot name into the name attribute. Examples:

  • <slot>...</slot><k:slot>...</k:slot>
  • <slot:header>...</slot:header><k:slot name="header">...</k:slot>

Layouts

Kirbys layout plugin is deprecated in favor of snippets. Replace <layout> with a non-closing snippet:

<!-- snippets/layouts/default.kirby -->
<main><?= $slots->default() ?></main>
<!-- templates/default.kirby -->
<k:layouts/default>

<h1>Some Content</h1>

Automatic Migration

Search and replace with these regexes:

  • <(/)?snippet:<$1k:
  • <slot><k:slot>
  • <slot:([\w/]+)><slot name="$1">
  • </slot(:[\w/]+)?><\k:slot>
  • <layout:([\w/]+)(\s*/)?><k:layouts/$1>