Add unorm.d.ts header and unorm tests file

This commit is contained in:
Christopher Brown
2015-06-10 12:39:40 -05:00
parent 5ea1c5b513
commit e75a0e9951
2 changed files with 16 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
/// <reference path="unorm.d.ts" />
import unorm = require("unorm");
function listNormalizations(raw: string) {
return [
unorm.nfd(raw),
unorm.nfkd(raw),
unorm.nfc(raw),
unorm.nfkc(raw),
];
}
+5
View File
@@ -1,3 +1,8 @@
// Type definitions for unorm 1.3.3
// Project: https://github.com/walling/unorm
// Definitions by: Christopher Brown <https://github.com/chbrown>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
declare module unorm {
interface Static {
nfd(str: string): string;