replace-ext

Replaces a file extension with another one

replace-ext

Packagereplace-ext
Description Replaces a file extension with another one
Node Version >= 0.4
var replaceExt = require('replace-ext');
 
var path = '/some/dir/file.js';
var npath = replaceExt(path, '.coffee');
 
console.log(npath); // /some/dir/file.coffee