format/haml.js
/**
 * Updates formatting properties for given output node
 * NB Unlike HTML, HAML is indent-based format so some formatting options from
 * `profile` will not take effect, otherwise output will be broken
 * @param  {OutputNode} outNode Output wrapper of parsed abbreviation node
 * @param  {Profile}    profile Output profile
 * @return {OutputNode}
 */
Updates formatting properties for given output node
NB Unlike HTML, HAML is indent-based format so some formatting options from
`profile` will not take effect, otherwise output will be broken
@param  {OutputNode} outNode Output wrapper of parsed abbreviation node
@param  {Profile}    profile Output profile
@return {OutputNode}
Updates formatting properties for given output node NB Unlike HTML HAML is indent - based format so some formatting options from ` profile ` will not take effect otherwise output will be broken @param { OutputNode } outNode Output wrapper of parsed abbreviation node @param { Profile } profile Output profile @return { OutputNode }
function updateFormatting(outNode, profile) {
	const node = outNode.node;
	if (!node.isTextOnly && node.value) {
		outNode.beforeText = reNl.test(node.value)
			? outNode.newline + outNode.indent + profile.indent(1)
			: ' ';
	}
	return outNode;
}
function updateFormatting ( outNode , profile ) { const node = outNode . node ; if ( ! node . isTextOnly && node . value ) { outNode . beforeText = reNl . test ( node . value ) ? outNode . newline + outNode . indent + profile . indent ( 1 ) : ' ' ; } return outNode ; }
Updates formatting properties for given output node
 NB Unlike HTML, HAML is indent-based format so some formatting options from
 `profile` will not take effect, otherwise output will be broken
 @param  {OutputNode} outNode Output wrapper of parsed abbreviation node
 @param  {Profile}    profile Output profile
 @return {OutputNode}
Updates formatting properties for given output node NB Unlike HTML HAML is indent - based format so some formatting options from ` profile ` will not take effect otherwise output will be broken @param { OutputNode } outNode Output wrapper of parsed abbreviation node @param { Profile } profile Output profile @return { OutputNode }
// node with text: put a space before single-line text