@solvprotocol/upgrade-safe-transpiler
Version:
Solidity preprocessor used to generate OpenZeppelin Contracts Upgrade Safe.
12 lines • 509 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.formatLines = void 0;
const lodash_1 = require("lodash");
function formatLines(indent, lines) {
function indentEach(indent, lines) {
return lines.map(line => Array.isArray(line) ? indentEach(indent + 1, line) : line && ' '.repeat(indent) + line);
}
return (0, lodash_1.flatten)(indentEach(indent, lines)).join('\n') + '\n';
}
exports.formatLines = formatLines;
//# sourceMappingURL=format-lines.js.map