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

Add replace-ext
This commit is contained in:
Horiuchi_H
2016-01-26 11:25:21 +09:00
2 changed files with 16 additions and 0 deletions
+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;
}