Confluence Macro. Render Storage format on page

My template in vm:

<ac:link><ri:user ri:username="${userName}"/></ac:link>

Want to render storage format in macro output as normal html

Only way that i found, just process my velocity template by xhtmlContent

xhtmlContent.convertStorageToView(storage, conversionContext)

but it is take a lot of time

Is any native way possible?

We are using com.atlassian.confluence.content.render.xhtml.FormatConverter.convertToViewFormat. This is fast enough for us.

As i see in realization of method it works same way

Can you give examples of using, please?
You process whole template, or just line with storage format?

in my case if we need a lot for rendering (for example, 100+ users), this process take a lot of time.

Any tips for render storage format by Javascript?

You can convert an entire page of storage format, so you can just join multiple users and convert it once.
To convert storage format using JavaScript you can use this function from Atlaskit: Examples – Atlaskit