Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[wip] Add Handlebars support and escaping @@ tags in markdown code #34

Closed
wants to merge 2 commits into from

Conversation

vladnega
Copy link

Fixes #33. You can now write the following in your markdown files and the @@ tag won't cause the respective function to be called:

    ```
    @@include(api.html)
    ```

The above would simply generate the following in your final HTML file:

@@include(api.html)

I've also added Handlebars partials support. This can be called in your markdown file using:

@@render(path_to_partial.html,path_to_data.json)

All functions return user friendly error messages to help him debug the code.

More functions like include and render can be easily added to the C# code. Please have a look at the PartialsSelector function.

seemantr and others added 2 commits March 10, 2016 09:58
@FransBouma
Copy link
Owner

Please only ready-to-merge PRs with a single feature which is complete. A lot of code changes in your PR and it includes a change that was postponed (the htm->html) change, as it needs configuration and better handling (this is in progress).

Your change alters the regexp, but that's not what is intended with #33. In #33, the parsing of @@include has to take place in the markdowndeep parser so context where @@include is used is taken into account. A regexp just matches everywhere and I don't want a parser relying on that. THe current code (with the regexp) is working but needs to be replaced by a non-regexp solution.

@FransBouma FransBouma closed this Mar 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants