Sha256: 46a973ec2833d6c62d85204bc5057152b001b8265f4838ec2fe4a982cca8eb7d

Contents?: true

Size: 394 Bytes

Versions: 8

Compression:

Stored size: 394 Bytes

Contents

const { concat, group, hardline, indent, join } = require("../../prettier");

// https://haml.info/docs/yardoc/file.REFERENCE.html#filters
function filter(path, _opts, _print) {
  const { value } = path.getValue();

  return group(
    concat([
      ":",
      value.name,
      indent(concat([hardline, join(hardline, value.text.trim().split("\n"))]))
    ])
  );
}

module.exports = filter;

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
prettier-1.5.5 src/haml/nodes/filter.js
prettier-1.5.4 src/haml/nodes/filter.js
prettier-1.5.3 src/haml/nodes/filter.js
prettier-1.5.2 src/haml/nodes/filter.js
prettier-1.5.1 src/haml/nodes/filter.js
prettier-1.5.0 src/haml/nodes/filter.js
prettier-1.4.0 src/haml/nodes/filter.js
prettier-1.3.0 src/haml/nodes/filter.js