From 85efa3dca32e9eaa329ae582a427446b7470d0ce Mon Sep 17 00:00:00 2001 From: Oliver Kossin Date: Wed, 23 Dec 2020 11:11:05 +0100 Subject: [PATCH 1/4] Add Config for snippets in Subfolder --- cookbook/override-dir-structure.rst | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/cookbook/override-dir-structure.rst b/cookbook/override-dir-structure.rst index f9ae7b5e..e1c78536 100644 --- a/cookbook/override-dir-structure.rst +++ b/cookbook/override-dir-structure.rst @@ -36,5 +36,23 @@ generated it with ``npm install`` and ``npm run build`` into your new directory. sulu_admin: json_manifest_path: "%kernel.project_dir%/public/your/new/path/manifest.json" + +Load Snippets from a Subfolder +------------------------------ +By the means of configuration in `config/packages/sulu_admin.yaml` according to the following scheme +it is also possible to load snippet templates from custom folders. + +.. code-block:: yaml + + sulu_core: + content: + structure: + paths: + event_snippets: + path: "%kernel.project_dir%/config/template/events/snippets/" + type: "snippet" + +In this example, a new Events folder has been specified. It is important that the key for the configuration remains unique for each config. + .. _Symfony documentation: https://symfony.com/doc/current/configuration/override_dir_structure.html .. _public-dir: https://symfony.com/doc/current/configuration/override_dir_structure.html#override-the-public-directory From e82769612640643197087348a637e9e396ad2800 Mon Sep 17 00:00:00 2001 From: Oliver Kossin Date: Fri, 14 May 2021 09:21:37 +0200 Subject: [PATCH 2/4] Change Doc to Bundle Docs --- bundles/snippet.rst | 19 +++++++++++++++++++ cookbook/override-dir-structure.rst | 19 ------------------- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/bundles/snippet.rst b/bundles/snippet.rst index 31ba1afd..366e6e1b 100644 --- a/bundles/snippet.rst +++ b/bundles/snippet.rst @@ -74,3 +74,22 @@ Properties ---------- Properties are the same as Page :doc:`../book/templates`. + + + +Load Snippets from a Subfolder +------------------------------ +By the means of configuration in `config/packages/sulu_admin.yaml` according to the following scheme +it is also possible to load snippet templates from custom folders. + +.. code-block:: yaml + + sulu_core: + content: + structure: + paths: + event_snippets: + path: "%kernel.project_dir%/config/template/events/snippets/" + type: "snippet" + +In this example, a new Events folder has been specified. It is important that the key for the configuration remains unique for each config. diff --git a/cookbook/override-dir-structure.rst b/cookbook/override-dir-structure.rst index e1c78536..ca07ed84 100644 --- a/cookbook/override-dir-structure.rst +++ b/cookbook/override-dir-structure.rst @@ -35,24 +35,5 @@ generated it with ``npm install`` and ``npm run build`` into your new directory. packages: sulu_admin: json_manifest_path: "%kernel.project_dir%/public/your/new/path/manifest.json" - - -Load Snippets from a Subfolder ------------------------------- -By the means of configuration in `config/packages/sulu_admin.yaml` according to the following scheme -it is also possible to load snippet templates from custom folders. - -.. code-block:: yaml - - sulu_core: - content: - structure: - paths: - event_snippets: - path: "%kernel.project_dir%/config/template/events/snippets/" - type: "snippet" - -In this example, a new Events folder has been specified. It is important that the key for the configuration remains unique for each config. - .. _Symfony documentation: https://symfony.com/doc/current/configuration/override_dir_structure.html .. _public-dir: https://symfony.com/doc/current/configuration/override_dir_structure.html#override-the-public-directory From a39d6845cfbbc739b3f6a1a9c14039885ba0bede Mon Sep 17 00:00:00 2001 From: nnatter Date: Fri, 14 May 2021 10:11:19 +0200 Subject: [PATCH 3/4] Update cookbook/override-dir-structure.rst --- cookbook/override-dir-structure.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/cookbook/override-dir-structure.rst b/cookbook/override-dir-structure.rst index ca07ed84..f9ae7b5e 100644 --- a/cookbook/override-dir-structure.rst +++ b/cookbook/override-dir-structure.rst @@ -35,5 +35,6 @@ generated it with ``npm install`` and ``npm run build`` into your new directory. packages: sulu_admin: json_manifest_path: "%kernel.project_dir%/public/your/new/path/manifest.json" + .. _Symfony documentation: https://symfony.com/doc/current/configuration/override_dir_structure.html .. _public-dir: https://symfony.com/doc/current/configuration/override_dir_structure.html#override-the-public-directory From 0d8f1853275a68cb76eb049f2c1029714a1518aa Mon Sep 17 00:00:00 2001 From: nnatter Date: Fri, 14 May 2021 10:12:28 +0200 Subject: [PATCH 4/4] Update bundles/snippet.rst --- bundles/snippet.rst | 2 -- 1 file changed, 2 deletions(-) diff --git a/bundles/snippet.rst b/bundles/snippet.rst index 366e6e1b..3ac51136 100644 --- a/bundles/snippet.rst +++ b/bundles/snippet.rst @@ -75,8 +75,6 @@ Properties Properties are the same as Page :doc:`../book/templates`. - - Load Snippets from a Subfolder ------------------------------ By the means of configuration in `config/packages/sulu_admin.yaml` according to the following scheme