biofriction-wp-theme/node_modules/modify-filename
jorge a7910c81a8 moved to new repo 2021-10-26 14:18:09 +02:00
..
index.js moved to new repo 2021-10-26 14:18:09 +02:00
license moved to new repo 2021-10-26 14:18:09 +02:00
package.json moved to new repo 2021-10-26 14:18:09 +02:00
readme.md moved to new repo 2021-10-26 14:18:09 +02:00

readme.md

modify-filename Build Status

Modify the filename in a path

Install

$ npm install --save modify-filename

Usage

var modifyFilename = require('modify-filename');

modifyFilename('src/unicorn.png', function (filename, extension) {
	return filename + '-rainbow' + extension;
});
//=> 'src/unicorn-rainbow.png'

modifyFilename(['src/unicorn.png', 'src/pony.png'], function (filename, extension) {
	return filename + '-rainbow' + extension;
});
//=> ['src/unicorn-rainbow.png', 'src/pony-rainbow.png']

License

MIT © Sindre Sorhus