I am building a static website using HTML templates and eleventy. I have some front matter data e.g. the page's title. That data also includes an array of items I want to display. The official documentation for Eleventy doesn't include sample code for arrays. The example for collections doesn't work here. What's the right syntax?
How can I iterate over an array of front matter data in Eleventy?
121 Views Asked by David Brossard At
1
There are 1 best solutions below
Related Questions in YAML
- Get current Timestamp in CET format and concatenate with string in yml file
- How to generate random item from json file in yaml code for artilliery load testing?
- Github Actions/variable-mapper : Error: Unexpected token *** in JSON
- Traverse through nodes with a path and change a value in a YAML File using yaml-cpp
- JSYAML custom schema for INT
- Deploy Docker Image into AKS cluster using Azure Release Pipelines with the parameters like clustername, acr, resourcegroup
- Allow AWS API Gateway to return YAML format, when a specific JSON property equals YAML
- Does Golang Yaml Unmarshal Support accessing nested yaml through struct tags?
- How to escape angle brackets in YAML?
- Mark OpenAPI schema enum value as deprecated
- yaml.safe_load removes whitespaces if also contains a line break
- Convert Azure desired state configs (DSC) powershell scripts to JSON or YAML
- GCP Cloud Build deploying a scheduler job
- I'm having issues with YAML skipping a job, based on a parameter value passed into the YAML
- Ansible role variable is not defined
Related Questions in LIQUID
- Remove specific products from cart on change in shopify
- Blogs Standard URL Filter /Tagged/Tag Not Working - Shopify
- Liquid Template - How to map JSON object as a string to output field
- Eleventy site builder: Make JavaScript function available for Nunjucks templates
- Looker: Comparing Dynamic Dates with Liquid
- Liquibase 4.26 while importing the csv file it's taking long time
- Fill missing elements with previous one - Liquid, Shopify
- How to call a Cart Drawer in custom product section?
- Shopify Metafield List of Collections
- How would I close this space up on the right? Using Shopify liquid
- Unable to build dynamic iterative lists
- Resetting loop count on liquid on condition
- window.Shopify.settings is undefined. How do I access Shopify theme settings in JavaScript?
- How does Jekyll apply `include` outside of `<body>` tag?
- Checkout Page in Shopify
Related Questions in ELEVENTY
- Eleventy site builder: Make JavaScript function available for Nunjucks templates
- Client-side site search using combobox, most performant way to get the indexed results
- Eleventy/11ty paginate content in pages generated from global data
- Nunjucks and an Eleventy shortcode aren't connecting to each other
- TemplateLayoutPathResolver directory does not exist for component: _includes
- Adding Google for Jobs in Eleventy website
- How to sort global data in a template loop with Eleventy?
- How to get an absolute URL with the slugify filter in Eleventy Liquid templates?
- duplicate/clone and altering content in 11ty
- 11ty Site Working Locally, but Missing CSS and Bootstrap on GitHub Pages After Repository Restructure
- How to make Eleventy correctly build SCSS while in --serve mode?
- How to exclude files or folder from eleventy?
- How can I iterate over an array of front matter data in Eleventy?
- Specify default permalink in Eleventy?
- how can i use nunjucks to only show posts from the previous 30 days in eleventy?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Given the following sample front matter data (in yaml):
This is how the HTML template should iterate over the code: