{"name":"lpad-align","version":"1.0.2","description":"Left pad a string to align with the longest string in an array","license":"MIT","repository":{"type":"git","url":"https://github.com/kevva/lpad-align"},"author":{"name":"Kevin Mårtensson","email":"kevinmartensson@gmail.com","url":"https://github.com/kevva"},"engines":{"node":">=0.10.0"},"scripts":{"test":"node test.js"},"files":["index.js"],"keywords":["align","indent","lpad"],"dependencies":{"longest":"^0.2.1","lpad":"^1.0.0"},"devDependencies":{"ava":"^0.0.4"},"gitHead":"57836e8b5541a12bb18ed9db13caaf2eb6d7bb77","bugs":{"url":"https://github.com/kevva/lpad-align/issues"},"homepage":"https://github.com/kevva/lpad-align","_id":"lpad-align@1.0.2","_shasum":"4414640c6fb45ffaf36b74d5741101077cd74328","_from":".","_npmVersion":"2.0.0","_npmUser":{"name":"kevva","email":"kevinmartensson@gmail.com"},"maintainers":[{"name":"kevva","email":"kevinmartensson@gmail.com"}],"dist":{"shasum":"4414640c6fb45ffaf36b74d5741101077cd74328","tarball":"http://registry-npm.ywwl.com/lpad-align/download/lpad-align-1.0.2.tgz","integrity":"sha512-CzayG3qCdIU/2uoDVa/9FPI3yOOCgDyKT09Wx9uE/e6BsN8umP0pfD0ydyaMmBFEa1XOa/OX5ZA88ydxP/Gy7g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGNkjm03u1ymD56C/C+m1PJo+mHxPuMvdWiGUrpCXpVGAiBTFwFIFP9Q78mEZr/sJHw5nxcj6SwAApgWJA9S3yMpAw=="}],"size":954,"noattachment":false,"key":"/lpad-align/-/lpad-align-1.0.2.tgz"},"directories":{},"readme":"# lpad-align [![Build Status](https://travis-ci.org/kevva/lpad-align.svg?branch=master)](https://travis-ci.org/kevva/lpad-align)\n\n> Left pad a string to align with the longest string in an array\n\n## Install\n\n```\n$ npm install lpad-align\n```\n\n## Usage\n\n```js\nconst lpadAlign = require('lpad-align');\n\nconst words = [\n\t'foo',\n\t'foobar',\n\t'foobarcat'\n];\n\nfor (const x of words) {\n\tconsole.log(lpadAlign(x, words, 4));\n}\n\n/*\n\t\t  foo\n\t   foobar\n\tfoobarcat\n */\n```\n\n## API\n\n### lpadAlign(string, array, indent)\n\n#### string\n\nType: `string`\n\nString that will be padded.\n\n#### array\n\nType: `Array`\n\nArray to align against.\n\n#### indent\n\nType: `number`\\\nDefault: `4`\n\nIndentation to prepend the string with.\n\n## CLI\n\n```\n$ npm install --global lpad-align\n```\n\n```\n  Usage\n    $ cat <file> | lpad-align\n\n  Example\n    $ cat unicorn.txt | lpad-align\n          foo\n       foobar\n    foobarcat\n```\n","publish_time":1414158619669,"_cnpm_publish_time":1414158619669,"dist-tags":{"latest":"3.0.0"}}