Skip to content

Commit

Permalink
Export format function from dots node format.
Browse files Browse the repository at this point in the history
See #76.
  • Loading branch information
flatheadmill committed Oct 21, 2019
1 parent 27a110e commit 3939f67
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion libexec/dots/node/format.js
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,10 @@ function format (json) {
return $([source]).replace(/^(\s+)\/\//gm, '$1 ')
}

module.exports = format

console.log(format(json))
if (module === process.mainModule) {
console.log(format(json))
}

// vim: set tw=0:

0 comments on commit 3939f67

Please sign in to comment.