Skip to content
This repository was archived by the owner on Jul 19, 2019. It is now read-only.

WIP - Add handlebars template to allow nested pages to access root level assets#25

Open
ByronDDelpinal wants to merge 2 commits intoCoffeeAndCode:masterfrom
ByronDDelpinal:master
Open

WIP - Add handlebars template to allow nested pages to access root level assets#25
ByronDDelpinal wants to merge 2 commits intoCoffeeAndCode:masterfrom
ByronDDelpinal:master

Conversation

@ByronDDelpinal
Copy link

Addresses issue #24

Things done:

  • Added a handlebars default helper to the template that allows nested pages to access root level assets. Previously, trying to link to a root level asset from a nested page required you to specify the relative URL yourself.
  • Provided example usage of the helper in the template files.

How to use:

  • When referencing anything from an href or src property in markup, wrap in with the nestedUrl helper like this:
<a href="{{nestedUrl 'index.html'}}">Home</a>
<img alt="" src="{{nestedUrl 'images/image.png'}}">

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant