Strip indentation of multiline strings based on length of the last line.
npm i panic-fn
import { m } from "https://deno.land/x/multiline_str/mod.ts";
import { m } from "multiline-str";
console.log(m`
Indentation is magically removed.
No more whitespace junk before text.
`);
console.log(m`
You control indentation with the length of the last line
this ---> `);
console.log(m`
|Important stuff
everything else |more important stuff
will be removed |the most important stuff
|`);
console.log(m`
001 | You can even
002 | do some
003 | weird things
*** | `);
This module was created using denoland/dnt.
This project is Mit Licensed.