Skip to content

Commit e95cd6e

Browse files
chore: update versions (#253)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 7672842 commit e95cd6e

File tree

3 files changed

+15
-14
lines changed

3 files changed

+15
-14
lines changed

.changeset/large-kings-show.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# vite-plugin-static-copy
22

3+
## 4.1.0
4+
5+
### Minor Changes
6+
7+
- [#251](https://github.com/sapphi-red/vite-plugin-static-copy/pull/251) [`7672842`](https://github.com/sapphi-red/vite-plugin-static-copy/commit/767284229162b4f0bd40698cc7e9b9478a2b156e) Thanks [@sapphi-red](https://github.com/sapphi-red)! - Add `name` property to the `rename` object form and allow rename functions to return a `RenameObject`. The `name` property replaces the file's basename (filename + extension), and can be combined with `stripBase` to both flatten directory structure and rename the file in one step. Rename functions can now return `{ name, stripBase }` objects instead of only strings, making it easier to declaratively control output paths from dynamic rename logic.
8+
9+
```js
10+
// node_modules/lib/dist/index.js → vendor/lib.js
11+
{ src: 'node_modules/lib/dist/index.js', dest: 'vendor', rename: { name: 'lib.js', stripBase: true } }
12+
13+
// src/pages/events/test.html → dist/events/index.html
14+
{ src: 'src/pages/**/*.html', dest: 'dist/', rename: { stripBase: 2, name: 'index.html' } }
15+
```
16+
317
## 4.0.1
418

519
### Patch Changes

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vite-plugin-static-copy",
3-
"version": "4.0.1",
3+
"version": "4.1.0",
44
"description": "rollup-plugin-copy for vite with dev server support.",
55
"type": "module",
66
"main": "./dist/index.js",

0 commit comments

Comments
 (0)