Storyblok Raises $80M Series C - Read News

Skip to main content
Browse apps

Requires Business plan

Storyblok GmbH
Last update
Advanced paths
Programmable preview paths
Advanced paths

When installing this app you get a new field in the folder dialog which lets you define the "Real path". Be aware that this will change the preview path of all your existing content items and you need to define the "Real path" for every folder manually.

The "Real path" is the path where the visual preview points to.

The app has been made for following scenarios:

  • You have root folders that should point to different preview domains
  • You have different preview domains based on the selected language
  • You have a url structure that uses other separators than slashes. Example: instead of
  • You have virtual folders. Example: instead of

Templating syntax

The "Real path" is programmable with the templating engine Squirelly and following context is available:

Attention: The folder context variable is only available in the real path of the folder and not on the real path of the story.

  • story The object of the current
  • lang The currently selected language
  • branch_id The current branch id
  • env_location The current environment location
  • env_name The current environment name
  • folder The object of the folder of the path (ONLY available on the folder real path)

Following a few path template examples:

Use when the language is "de" and otherwise use{{lang}}

{{if(options.lang == 'de')}}{{#else}}{{lang}}{{/if}}

Use the folder slug as "Real path"

{{folder.slug}} or {{folder.translated_slug}}

Use a custom preview url only when the environment is not "Default".

{{if(options.env_name == 'Default')}}{{/if}}