# Single paragraph rendered withing shortcode using {{ .Inner }} is missing \<p\> tag

**URL:** <https://discourse.gohugo.io/t/single-paragraph-rendered-withing-shortcode-using-inner-is-missing-p-tag/21155>\
**Category:** support\
**Created:** [October 7, 2019, 6:18am UTC](https://discourse.gohugo.io/t/single-paragraph-rendered-withing-shortcode-using-inner-is-missing-p-tag/21155 "2019-10-07T06:18:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![looeee](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/looeee/32/9668_2.png) [@looeee](https://discourse.gohugo.io/u/looeee)\
**Post date:** [October 7, 2019, 6:18am UTC](https://discourse.gohugo.io/t/single-paragraph-rendered-withing-shortcode-using-inner-is-missing-p-tag/21155/1 "2019-10-07T06:18:52Z")

</div>

I have a very simple shortcode that wraps the content in aside tags:

```auto
shortcodes/aside.html

<aside>
{{ .Inner | markdownify }}
</aside>

```

Generally it works as expected, for example:

**Input** :

```auto
{{% aside %}}
The first paragraph

The second paragraph
{{% /aside %}}

```

**Output** :

```auto
<aside>
<p>The first paragraph</p>

<p>The second paragraph</p>
</aside>

```

However, if there is just a single paragraph inside then the `<p>` tags are missing:

**Input** :

```auto
{{% aside %}}
A single paragraph
{{% /aside %}}

```

**Output** :

```auto
<aside>
A single paragraph
</aside>

```

I’ve tried adding blank lines around the single paragraph, but that doesn’t affect the output.

Hugo version: v0.58.3-4AAC02D4 windows/amd64

---

<div class="post-metadata">

**Author:** ![Grob](https://avatars.discourse-cdn.com/v4/letter/g/f14d63/32.png) [@Grob](https://discourse.gohugo.io/u/Grob)\
**Post date:** [October 7, 2019, 6:35am UTC](https://discourse.gohugo.io/t/single-paragraph-rendered-withing-shortcode-using-inner-is-missing-p-tag/21155/2 "2019-10-07T06:35:22Z")

</div>

Hi!

This is a known ‘bug’ caused by the markdown renderer, I guess.

[This hack](https://discourse.gohugo.io/t/prevent-markdownify-to-strip-first-p-tags/7854/11) I posted recently should help.

---

<div class="post-metadata">

**Author:** ![maiki](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/maiki/32/16384_2.png) [@maiki](https://discourse.gohugo.io/u/maiki)\
**Post date:** [October 8, 2019, 2:24am UTC](https://discourse.gohugo.io/t/single-paragraph-rendered-withing-shortcode-using-inner-is-missing-p-tag/21155/3 "2019-10-08T02:24:15Z")

</div>


