From cfc0c4a7ebb22748b06e88f369a7ad7a2e9aea2c Mon Sep 17 00:00:00 2001 From: Jon Uhlmann Date: Thu, 8 Feb 2024 16:31:00 +0100 Subject: [PATCH] TASK: Prettier readme --- README.md | 40 +++++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 232a2f0..3295169 100644 --- a/README.md +++ b/README.md @@ -4,46 +4,46 @@ "Quantum slipstream transcends the normal warp barrier by penetrating the quantum barrier with a focused quantum field." -The slipstream package allows defining header requirements with presentational fusion by labeling the required tags with a unique attribute. They are later deduplicated and moved to the target position. This allows defining additional the JS and CSS requirements directly with the presentational fusion components. +The slipstream package allows defining header requirements with presentational fusion by labeling the required tags with +a unique attribute. They are later deduplicated and moved to the target position. This allows defining additional the JS +and CSS requirements directly with the presentational fusion components. ### Authors & Sponsors * Martin Ficzel - ficzel@sitegeist.de -*The development and the public releases of this package is generously sponsored -by our employer http://www.sitegeist.de.* +> The development and the public releases of this package is generously sponsored by our employer [**site**geist]. ## Usage -You can mark any HTML fragment to be moved to the head of the document by -adding a `data-slipstream` attribute. +You can mark any HTML fragment to be moved to the head of the document by adding a `data-slipstream` attribute. ```html - -
your component
+ +
your component
``` -The slipstream middleware will parse the entire page and detect all those tags. The tags are then removed from the original -location and are appended to the header. Every tag is added only once, so if multiple components require the same JS, only one -is added to the given location. +The slipstream middleware will parse the entire page and detect all those tags. The tags are then removed from the +original location and are appended to the header. Every tag is added only once, so if multiple components require the +same JS, only one is added to the given location. -By defining the `data-slipstream` attribute with an XPath, the target can be altered. +By defining the `data-slipstream` attribute with an XPath, the target can be altered. ```html - -
your component
+ +
your component
``` To prepend the tag to the given target, you can add the `data-slipstream-prepend` attribute: ```html - - + + ``` When the setting `Sitegeist.Slipstream.debugMode` is enabled, HTML comments are rendered to mark where tags were removed -and inserted. This is enabled in Development Context by default. -If the setting `Sitegeist.Slipstream.removeSlipstreamAttributes` is enabled, the attributes from slipstream get removed. +and inserted. This is enabled in Development Context by default. +If the setting `Sitegeist.Slipstream.removeSlipstreamAttributes` is enabled, the attributes from slipstream get removed. This is disabled in Development Context by default. ## Inner working and performance @@ -53,8 +53,8 @@ This header is added to Neos.Neos:Page and Sitegeist.Monocle:Preview.Page alread Neos and Monocle right away. You will have to add the header `X-Slipstream: Enabled` for other controllers. Since the response body is parsed and modified, this adds a minor performance penalty to every request. However -the package is designed to work together with Flowpack.FullpageCache, which will in turn cache the whole result -and mitigate the slight performance drawback. +the package is designed to work together with Flowpack.FullpageCache, which will in turn cache the whole result +and mitigate the slight performance drawback. ## Installation @@ -65,3 +65,5 @@ We use semantic-versioning so that every breaking change will increase the major ## Contribution We will gladly accept contributions. Please send us pull requests. + +[**site**geist]: http://www.sitegeist.de