Questions tagged [yaml-front-matter]

126 questions
0
votes
1 answer

How do I access a date value from the metadata in my HTML files?

I installed the spatie/yaml-front-matter package into my Laravel project to access metadata in my HTML files. Unfortunately, I cannot sort the files by date because the date property in the metadata is returning a null value. My operating system is…
0
votes
1 answer

Correct YAML syntax from frontmatter

I need to achieve this frontmatter: services: - service: serviceName: Service 1 serviceDesc: Blah - service: serviceName: Service 2 serviceDesc: Blah - service: serviceName: Service 3 …
kukihi
  • 23
  • 3
0
votes
1 answer

Adding og images to VitePress

I've seen that in the VitePress .md files you can add meta description and keywords like this, head: - - meta - name: description content: my custom description But I can't seem to figure out how to add og:title or og:image, it seems…
Kelvin Zhao
  • 2,243
  • 3
  • 22
  • 31
0
votes
1 answer

Embedding a youtube video in markdown field in Netlify CMS

I'm developing a site that uses Next.js (static/pre-rendered) with Netlify CMS as a way to manage content, and also run the blog. For each blog post, I have a few fields such as title, author etc that are string fields, and I have a markdown field…
0
votes
1 answer

Hugo won't render front matter variables when I publish to Netlify

I am building a hugo blog site and I have some front matter that I would like to get rendered in the layouts. When I view the results on my localhost:1313, I can see the front matter being populated, but when I host the site on Netlify, the front…
Tyler Morales
  • 1,440
  • 2
  • 19
  • 56
0
votes
1 answer

Gridsome source-filesystem add tag description

I'm using @gridsome/source-filesystem with this config: { use: '@gridsome/source-filesystem', options: { typeName: 'Post', path: 'content/posts/**/*.md', refs: { tags: { typeName: 'Tag', create: true }, …
0
votes
1 answer

Is possible to have a Front Matter header in a script?

I was thinking in how to include some metadata in my script files in a way that other scripts could process this information without interfering in its ./ execution. YAML Front Matter came to my mind, but obviously its --- syntax produce error…
artu-hnrq
  • 1,343
  • 1
  • 8
  • 30
0
votes
0 answers

Creating images from Jekyll posts

I am looking to "automatically" create images from Jekyll posts. Either dynamically or on site build, I am not picky. I know I can create images from html and css, so this must be possible, but I am not sure where to start to do it in Jekyll. From…
0
votes
0 answers

Is there a way to dynamically select values from YAML front matter in Grav using twig templates?

I am working with Grav and trying to dynamically select a specific array to use from a config variable based on the current active language. I know I can use if and else if statements, but I would rather not do that because each time another array…
Peter Kaufman
  • 752
  • 1
  • 6
  • 18
0
votes
1 answer

Set a different hero image on main layout according to the post/url (retrieving the data from graphQL) [GATSBY]

EDIT: There is a demo on this Github repository. I need to change the main layout hero-image of my blog according to the post/page (its slug). Every post has a hero-image, setted in the frontmatter info. I tried everything but: 1. either it shows…
Santiago
  • 361
  • 4
  • 21
0
votes
1 answer

Jekyll default (layout) Front Matter doesn't work: fixed

I was trying to set different layouts depending on the directory of the pages, like: defaults: - scope: path: "" type: "pages" values: layout: "default" - scope: path: "www/grid" type: "pages" …
Matteo Rizzo
  • 147
  • 1
  • 2
  • 11
0
votes
1 answer

Jekyll Front Matter Path Doesn't Work

I have two sections of my site, intro and core, that I want to have two different navigation bars. Here is my navigation.yml main: - title: "Intro" url: /intro/intro - title: "Core" url: /core/core-1 intro: - title: Introduction …
szxnyc
  • 2,495
  • 5
  • 35
  • 46
0
votes
1 answer

How does Gatsby serve up Markdown frontmatter with GraphQL?

The most interesting feature of Gatsby to me is gatsby-source-filesystem's ability to tap into a directory of markdown files and serve up that static content to React via GraphQL queries. In essence, flat files with YAML frontmatter that are…
Wray Bowling
  • 2,346
  • 2
  • 16
  • 19
0
votes
1 answer

Assign a font awesome icon to a tag that covers the entire website

I've got this YAML front matter on each post: --- title: Title subtitle: Description date: 2017-09-26 13:15:18 +0200 post-type: front-end tages: - HTML - CSS - jQuery --- And I've got this code to show each tag in a list. {%…
Vasco
  • 191
  • 1
  • 2
  • 12
0
votes
0 answers

BigCommerce Displaying Brands on Homepage (Stencil)

I need to display a collection of brands on the home page of a BigCommerce theme. The theme is using Stencil and Handlebars.js. My Front-matter block at the top of the page is as follows: YAML at the top of the page. --- carousel: true products: …
1 2 3
8 9