From 84a8620a8234b471e76ff57ff2c350642a18ca56 Mon Sep 17 00:00:00 2001 From: Sam Saint-Pettersen Date: Tue, 4 Aug 2015 14:04:25 +0100 Subject: [PATCH 1/3] Type definitions and tests for path-case --- path-case/path-case.d.ts | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 path-case/path-case.d.ts diff --git a/path-case/path-case.d.ts b/path-case/path-case.d.ts new file mode 100644 index 000000000..bb577cac8 --- /dev/null +++ b/path-case/path-case.d.ts @@ -0,0 +1,9 @@ +// Type definitions for path-case +// Project: https://github.com/blakeembrey/path-case +// Definitions by: Sam Saint-Pettersen +// Definitions: https://github.com/borisyankov/DefinitelyTyped + +declare module "path-case" { + function pathCase(string: string, locale?: string): string; + export = pathCase; +} From 6a43c576ef95f57e5e4f48e0e94b5f02d27679c1 Mon Sep 17 00:00:00 2001 From: Sam Saint-Pettersen Date: Tue, 4 Aug 2015 14:05:01 +0100 Subject: [PATCH 2/3] Create path-case-tests.ts --- path-case/path-case-tests.ts | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 path-case/path-case-tests.ts diff --git a/path-case/path-case-tests.ts b/path-case/path-case-tests.ts new file mode 100644 index 000000000..863559b2e --- /dev/null +++ b/path-case/path-case-tests.ts @@ -0,0 +1,9 @@ +/// + +import pathCase = require('path-case'); + +console.log(pathCase('string')); // => "string" +console.log(pathCase('camelCase')); // => "camel/case" +console.log(pathCase('sentence case')); // => "sentence/case" + +console.log(pathCase('MY STRING', 'tr')); // => "my.strıng" From 471c254078813643aad9c278c58121eccf58df66 Mon Sep 17 00:00:00 2001 From: Sam Saint-Pettersen Date: Tue, 4 Aug 2015 14:05:44 +0100 Subject: [PATCH 3/3] Type definitions and tests for path-case --- path-case/path-case-tests.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/path-case/path-case-tests.ts b/path-case/path-case-tests.ts index 863559b2e..8c17cbd44 100644 --- a/path-case/path-case-tests.ts +++ b/path-case/path-case-tests.ts @@ -6,4 +6,4 @@ console.log(pathCase('string')); // => "string" console.log(pathCase('camelCase')); // => "camel/case" console.log(pathCase('sentence case')); // => "sentence/case" -console.log(pathCase('MY STRING', 'tr')); // => "my.strıng" +console.log(pathCase('MY STRING', 'tr')); // => "my.strıng"