chrisdiana / chrisdiana/cms.js
Can't put url on post metadata and pull them via the template engine
- Dominant language
- JavaScript
- Stars
- 3.1k
- Forks
- 279
- PR merge metrics
- No merged PRs in 30d
Description
I was trying to put urls in the post listings. Sort of a featured image for each post.
```markdown
---
layout: post
title: New feature TEST
excerpt: Cum sociis natoque penatibus et magnis dis parturient montes...
author: Chris
image: http://placehold.it/300x300
---
```
As a test I've put a url.
Then modified the layout on the post listings to reflect the changes:
```html
<% if(post.image) { %>
<% } %>
```
and the output html looks like this:
```html
```
Is it intentional? I suppose the // in the url are getting escaped by themselves.
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the issue with the supplied Markdown front matter and template snippet, then trace how metadata is parsed and passed to the template engine. Confirm the fix by rendering a post listing and verifying that the complete URL, including its protocol, remains in the generated image element.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100