Merge pull request #7140 from DeividasBakanas/typing/replace-ext

Add replace-ext
This commit is contained in:
Horiuchi_H committed 2016-01-26 11:25:21 +09:00
commit 6321b73594
2 files changed
+16

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
/// <reference path="replace-ext.d.ts" />
import replaceExt = require('replace-ext');
var path: string = '/some/dir/file.js';
var npath: string = replaceExt(path, '.coffee');
+11
View File
@@ -0,0 +1,11 @@
// Type definitions for replace-ext 0.0.1
// Project: https://github.com/wearefractal/replace-ext
// Definitions by: Deividas Bakanas <https://github.com/DeividasBakanas>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare function replaceExt(npath: string, ext: string): string;
declare module 'replace-ext' {
export = replaceExt;
}