modify-filename

WebJar for modify-filename

License

License

MIT
GroupId

GroupId

org.webjars.npm
ArtifactId

ArtifactId

modify-filename
Last Version

Last Version

1.1.0
Release Date

Release Date

Type

Type

jar
Description

Description

modify-filename
WebJar for modify-filename
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/sindresorhus/modify-filename

Download modify-filename

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.npm/modify-filename/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>modify-filename</artifactId>
    <version>1.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/modify-filename/
implementation 'org.webjars.npm:modify-filename:1.1.0'
// https://jarcasting.com/artifacts/org.webjars.npm/modify-filename/
implementation ("org.webjars.npm:modify-filename:1.1.0")
'org.webjars.npm:modify-filename:jar:1.1.0'
<dependency org="org.webjars.npm" name="modify-filename" rev="1.1.0">
  <artifact name="modify-filename" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='modify-filename', version='1.1.0')
)
libraryDependencies += "org.webjars.npm" % "modify-filename" % "1.1.0"
[org.webjars.npm/modify-filename "1.1.0"]

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

modify-filename

Modify the filename in a path

Install

$ npm install modify-filename

Usage

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

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

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

License

MIT © Sindre Sorhus

Versions

Version
1.1.0