func (c *RenderController) Render(ctx *app.RenderRenderContext) error {
	content := ctx.Payload.Data.Attributes.Content
	markup := ctx.Payload.Data.Attributes.Markup
	if !rendering.IsMarkupSupported(markup) {
		return jsonapi.JSONErrorResponse(ctx, errors.NewBadParameterError("Unsupported markup type", markup))
	}
	htmlResult := rendering.RenderMarkupToHTML(content, markup)
	res := &app.MarkupRenderingSingle{Data: &app.MarkupRenderingData{
		ID:   uuid.NewV4().String(),
		Type: RenderingType,
		Attributes: &app.MarkupRenderingDataAttributes{
			RenderedContent: htmlResult,
		}}}
	return ctx.OK(res)
}
// Render runs the render action.
Render runs the render action.
// Render runs the render action .
func (c *RenderController) Render(ctx *app.RenderRenderContext) error {
	content := ctx.Payload.Data.Attributes.Content
	markup := ctx.Payload.Data.Attributes.Markup
	if !rendering.IsMarkupSupported(markup) {
		return jsonapi.JSONErrorResponse(ctx, errors.NewBadParameterError("Unsupported markup type", markup))
	}
	htmlResult := rendering.RenderMarkupToHTML(content, markup)
	res := &app.MarkupRenderingSingle{Data: &app.MarkupRenderingData{
		ID:   uuid.NewV4().String(),
		Type: RenderingType,
		Attributes: &app.MarkupRenderingDataAttributes{
			RenderedContent: htmlResult,
		}}}
	return ctx.OK(res)
}
func ( c * RenderController ) Render ( ctx * app . RenderRenderContext ) error { content := ctx . Payload . Data . Attributes . Content markup := ctx . Payload . Data . Attributes . Markup if ! rendering . IsMarkupSupported ( markup ) { return jsonapi . JSONErrorResponse ( ctx , errors . NewBadParameterError ( " " , markup ) ) } htmlResult := rendering . RenderMarkupToHTML ( content , markup ) res := & app . MarkupRenderingSingle { Data : & app . MarkupRenderingData { ID : uuid . NewV4 ( ) . String ( ) , Type : RenderingType , Attributes : & app . MarkupRenderingDataAttributes { RenderedContent : htmlResult , } } } return ctx . OK ( res ) }
Render runs the render action.
Render runs the render action .