Search

Showing 7 of 587 result(s)

/blog/2022/07/18/antlers-and-blade-formatters-behind-the-scenes#content-the-document-transformer

Both the Blade and Antlers TypeScript parsers have the concept of the document transformer. This special class takes the parsed results and converts them into a structured document that can be formatted with existing tools. These transformers do...

/blog/2022/11/01/a-beginners-guide-to-antlers-arrays-and-loops#content-conditionally-rendering-wrapper-elements

When working with arrays and lists of items, a frequent task we will encounter when building our sites is  wrapping  the final output in some container element. For example, the following Antlers template surrounds our dynamic output in an...

/blog/2022/11/01/a-beginners-guide-to-antlers-arrays-and-loops#content-managing-array-data-scope

Whenever we are inside a tag pair and attempt to access a variable that does not exist, Antlers will attempt to locate it somewhere else by moving "up" what is called the Cascade. In simple terms, it will continue searching for a variable at all...

/blog/2022/11/01/a-beginners-guide-to-antlers-arrays-and-loops#content-looping-keyvalue-pairs

In the previous section, we learned that creating a tag pair from an associative array or YAML map will extract the nested key/value pairs into new variables. However, there are times when it is desirable to loop over an associative array and...

/blog/2022/11/01/a-beginners-guide-to-antlers-arrays-and-loops#content-inserting-content-at-arbitrary-or-random-locations

It is not an uncommon requirement to be able to insert additional content within a listing of collection entries. An example of this may be to insert an advertisement at specific locations or to randomly insert supplementary or featured content...

/blog/2023/09/03/creating-a-hybrid-cache-system-for-statamic-part-three#content-bypassing-the-cache

Currently, our caching system doesn't cache pages viewed by logged-in users. However, if a page was cached before a user logs in, that cached page is served to all logged-in users. While this might work for some websites, it poses challenges when...

/blog/2023/09/03/creating-a-hybrid-cache-system-for-statamic#content-what-were-going-to-build

The goal of our custom caching system will be to get as close to the performance of the static HTML cache as we reasonably can without having to rely on Control Panel events for most cache invalidation, as well as support a few additional cache...