Search by

sandstorm / neos-nodetypes-folder

sandstorm

Folder nodetype for Neos CMS

Package info

github.com/sandstorm/neos-nodetypes-folder

Language:Gherkin

Type:neos-plugin

pkg:composer/sandstorm/neos-nodetypes-folder

Statistics

Installs: 3 084

Dependents: 0

Suggesters: 0

Stars: 2

v1.0.5 2026-10-05 08:32 UTC

README

Latest Stable Version

Note

This was originally a fork of breadlesscode/neos-nodetypes-folder. The original author and us decided to split maintenance of the package. While we maintain the package for all Neos versions >= 9, you can still use the original package for neos versions below 9. Just make sure to install the respective package (so either breadlesscode/neos-nodetypes-folder or sandstorm/neos-nodetypes-folder) and also use the correct nodetype: Breadlesscode.NodeTypes.Folder:Document.Folder or Sandstorm.NodeTypes.Folder:Document.Folder.

Package Neos Version
breadlesscode/neos-nodetypes-folder < 9.0
sandstorm/neos-nodetypes-folder >= 9.0

This Neos Plugin contains a folder node type. By default, a folder is rendered in the URI like any other page. Editors can hide it per folder with the "Hide URL path segment" toggle in the General tab of the inspector.

Hiding the URL path segment by default

To hide the URL path segment of new folders by default, override the NodeType default in your site package (it must require sandstorm/neos-nodetypes-folder, see Installation, so that your override is loaded last):

# Packages/Sites/Your.Site/NodeTypes/Override/Folder.yaml
'Sandstorm.NodeTypes.Folder:Mixin.HideUriSegment':
  properties:
    hideSegmentInUriPath:
      defaultValue: true

This only affects newly created folders — existing folders keep their stored value.

The main idea and code is from @sebobo from this Gist. Thanks for that!!!

Warning

This package overrides the DocumentUriPathProjection from the neos core!

Installation

Most of the time you have to make small adjustments to a package (e.g. the configuration in Settings.yaml). Because of that, it is important to add the corresponding package to the composer manfest of your theme package. Mostly this is the site package located under Packages/Sites/. To install it correctly, go to your theme package (e.g. Packages/Sites/Foo.Bar) and run the following command:

composer require sandstorm/neos-nodetypes-folder --no-update

The --no-update command prevents other dependencies from being updated. After the package was added to your theme composer.json, go back to the root of the Neos installation and run composer update. The package is now installed correctly.

Upgrade Instructions 1.x -> 2.0.0

Breaking: New folders now show their URL path segment by default (hideSegmentInUriPath defaults to false; before, it defaulted to true). Existing folders keep their stored value, so their URLs don't change.

To keep the previous behavior for newly created folders, add the NodeType override from Hiding the URL path segment by default to your site package.

Upgrade Instructions 1.0.0 -> 1.0.1

As we introduced a new Projection to catch URI path collisions, you need to set it up in the Content Repository after the package update:

  1. setup new Uri Projection ./flow cr:setup
  2. replay events on that Projection ./flow subscription:replay Neos.Neos:DocumentUriPathProjection
  3. flush cache to force re-rendering of menu ./flow flow:cache:flush