mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
15 lines
416 B
TypeScript
15 lines
416 B
TypeScript
import presuf = require('pre-suf');
|
|
|
|
presuf.ensureLeading('a', '/'); // $ExpectType string
|
|
presuf.removeLeading('a', '/'); // $ExpectType string
|
|
presuf.ensureEnding('a', '/'); // $ExpectType string
|
|
presuf.removeEnding('/a/ab/a', '/a'); // $ExpectType string
|
|
// $ExpectError
|
|
presuf.ensureLeading();
|
|
// $ExpectError
|
|
presuf.removeLeading();
|
|
// $ExpectError
|
|
presuf.ensureEnding();
|
|
// $ExpectError
|
|
presuf.removeEnding();
|