Partials Not Working For Output Formats

Sorry, i will try to explain myself better.

I have a blog with hugo where i use a AMP theme, and i use some shortcodes that add amp elements to my page, like amp-img.
Now i’m trying to use the new feature output formats to output my page in a way that Facebook Instant Article can understand.

I created a custom output format

[outputFormats.INSTANT] name = "instant" mediaType = "text/html" path="instant" rel = "instant" isPlainText = false isHTML = true NoUgly = false NotAlternative = false

and in the most parts it is working where well.

My problem is that a have a shortcode that adds the in instead of
So i have to customize this shortcode.

There is no page variable that inform which output format that i’m acessing, so the way that a i find was to use partial. Acording with the output format docs

All of the above examples can also include partials.

and

Hugo will now also detect the media type and output format of partials, if possible, and use that information to decide if the partial should be parsed as a plain text template or not.

Hugo will look for the name given, so you can name it whatever you want. But if you want it treated as plain text, you should use the file suffix and, if needed, the name of the Output Format ([partial name].[OutputFormat].[suffix]).

Soo i tried

to create the partials

  • test.html.html and test.instant.html
  • test.html + test.instant.html
  • test.html + test.instant.html

and call it like

  • {{partials “test” }}
  • {{partials “test.html” }}
    but it never use the outputformat customized one, just the default

if a use {{partials “test.instant.html” }} it shows that one, but it don’t solve my problem.

Thanks for the attention.
Sorry if i was not clear before