{"category":"text","endpoint":"https://setget.net/v1/tools/wrap-indent","examples":[{"input":{"prefix":"> ","text":"The quick brown fox jumps over the lazy dog.","width":20},"output":{"lines":3,"text":"> The quick brown\n> fox jumps over the\n> lazy dog."}},{"input":{"indent":4,"text":"def f():\n    return 1","width":0},"output":{"lines":2,"text":"    def f():\n        return 1"},"title":"Indent only"},{"input":{"reflow":true,"text":"one\ntwo\nthree\n\nfour","width":12},"output":{"lines":4,"text":"one two\nthree\n\nfour"},"title":"Reflow paragraphs"}],"input_schema":{"additionalProperties":false,"properties":{"dedent":{"default":false,"description":"First remove the indentation that all lines have in common.","type":"boolean"},"indent":{"default":0,"description":"Spaces to add to every line. A negative number removes up to that many leading spaces.","maximum":100,"minimum":-100,"type":"integer"},"prefix":{"default":"","description":"Text put at the start of every line, for example \"> \" or \"# \".","maxLength":40,"type":"string"},"reflow":{"default":false,"description":"Join the lines of each paragraph before wrapping, so short lines are filled up.","type":"boolean"},"text":{"description":"The text to wrap or indent.","examples":["The quick brown fox jumps over the lazy dog."],"type":"string"},"width":{"default":80,"description":"Longest line allowed, counting the indent and prefix. 0 leaves line lengths alone.","maximum":10000,"minimum":0,"type":"integer"}},"required":["text"],"type":"object"},"keywords":["word wrap","wrap text","hard wrap","line length","indent","dedent","unindent","quote text","reflow","80 columns","fold"],"related":["line-numbers","truncate-middle","text-chunk"],"slug":"wrap-indent","summary":"Hard-wrap text to a line width, add or remove indentation, and put a prefix such as \"> \" on every line.","tier":"inline","title":"Wrap and indent text","url":"https://setget.net/tools/wrap-indent"}
