mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-05-31 16:40:02 +00:00
32 lines
384 B
TypeScript
32 lines
384 B
TypeScript
import deindent = require('deindent');
|
|
|
|
// as a string function
|
|
deindent(`
|
|
this
|
|
is
|
|
the ${'end'}
|
|
my only
|
|
friend
|
|
the end
|
|
`);
|
|
|
|
// as a template tag
|
|
deindent`
|
|
this
|
|
is
|
|
the ${'end'}
|
|
my only
|
|
friend
|
|
the end
|
|
`;
|
|
|
|
// as a higher-order template tag
|
|
deindent(String.raw)`
|
|
this
|
|
is
|
|
the ${'end'}
|
|
my only
|
|
friend
|
|
the end
|
|
`;
|