How to access Content without markup rendering

Hi all,

Assuming, my file is
Page.RawContent is the content without shortcode replacement.
Page.Content is the content with shortcode replacement and markup rendering.

I need something in between.
Page.ParsedContent is the content with shortcode replacement only, without markup rendering.

As a workaround, I’m using .html extension instead of .md, but text editor is unhappy of that.

I could like use global configuration similar to BuildFuture to bypass renderContent method in page.go


Please give a concrete example of what you’d like to accomplish. I’m not understanding from the description you gave.

Hi @zwbetz,

Basically, I would like to build HTML pages from Markdown files by using templates/partials/shortcodes/sections/list… features from Hugo (without Markdown transformation).

The main issue is that my input files are Markdown and I’m not able to tell Hugo to not process to Markdown transformation.

In details, the process is following:

  • create some templates and shortcodes in layout
  • create site configuration file with custom variables
  • create Markdown with front-matter files in content directory (for instance,
  • request Hugo to process with only templates, shortcodes, variables but no Markdown transformation (i.e. don’t touch Markdown syntax)
  • the resulting file my_content.html will contain HTML with embedded Markdown that will be processed by Javascript when presenting the application

In other words, I would like to push the Markdown transformation from Hugo to Javascript.

I see what you mean now. I don’t think this can be done with Hugo, though.