Sublime-HTMLPrettify icon indicating copy to clipboard operation
Sublime-HTMLPrettify copied to clipboard

Issue while formatting handlebars

Open rastogiachyut opened this issue 8 years ago • 2 comments

This code:

	{{#isDealLink}}
	&nbsp;&nbsp;<a target="_blank" href="{{dealLink}}" class="weak">See offer details</a>
	{{/isDealLink}}

Is formatted to:

            {{#isDealLink}} &nbsp;&nbsp;
                <a target="_blank" href="{{dealLink}}" class="weak">See offer details</a> {{/isDealLink}}

I'd like it to be:

            {{#isDealLink}} &nbsp;&nbsp;
                <a target="_blank" href="{{dealLink}}" class="weak">See offer details</a>
            {{/isDealLink}}

are there some formatting options available for this? Please ignore indentation differences, what is want is for {{/isDealLink}} to be on a separate line. There seems to be a problem in the regex used, it looks for {{ instead of {{/ when indenting for the end.

rastogiachyut avatar May 31 '18 11:05 rastogiachyut

Please file this issue at https://github.com/beautify-web/js-beautify

victorporof avatar May 31 '18 14:05 victorporof

@victorporof Thanks.

rastogiachyut avatar Jun 13 '18 12:06 rastogiachyut