Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/fiery-cats-learn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@smoothtml/vite-plugin-sri": patch
---

Add THIRD-PARTY-NOTICES.txt to the published package, carrying the MIT license
and copyright for the bundled Vite-derived code.
4 changes: 0 additions & 4 deletions NOTICE
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,3 @@ Copyright 2026 Rishvic Pushpakaran.

This product includes software developed by
Rishvic Pushpakaran <rishvic@gmail.com>.

Portions derived from Vite (https://github.com/vitejs/vite),
copyright (c) 2019-present, VoidZero Inc. and Vite contributors,
licensed under MIT. See SPDX headers in the affected files.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ This plugin includes code adapted from [Vite](https://github.com/vitejs/vite) (
2019-present, VoidZero Inc. and Vite contributors, MIT-licensed). Specifically,
`src/html.ts` and `src/utils.ts` are derived from
`packages/vite/src/node/plugins/html.ts` and `packages/vite/src/node/utils.ts`
respectively. See the SPDX headers in those files and [`NOTICE`](./NOTICE) for
details.
respectively. See the SPDX headers in those files and
[`THIRD-PARTY-NOTICES.txt`](./THIRD-PARTY-NOTICES.txt) for details.

## License

Expand Down
29 changes: 29 additions & 0 deletions THIRD-PARTY-NOTICES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
@smoothtml/vite-plugin-sri bundles code derived from Vite
(https://github.com/vitejs/vite), specifically portions of
packages/vite/src/node/plugins/html.ts and packages/vite/src/node/utils.ts,
which are compiled into the published dist/ output. That code is licensed under
the MIT License, reproduced below.

------------------------------------------------------------------------

MIT License

Copyright (c) 2019-present, VoidZero Inc. and Vite contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
3 changes: 3 additions & 0 deletions THIRD-PARTY-NOTICES.txt.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
SPDX-FileCopyrightText: 2019-present, VoidZero Inc. and Vite contributors

SPDX-License-Identifier: MIT
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@
"./package.json": "./package.json"
},
"files": [
"dist"
"dist",
"NOTICE",
"CHANGELOG.md",
"THIRD-PARTY-NOTICES.txt"
],
"sideEffects": false,
"scripts": {
Expand Down
2 changes: 2 additions & 0 deletions tsdown.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

import { defineConfig } from "tsdown";

// Deps are externalized, not bundled. If you bundle one into dist/, add its
// attribution to THIRD-PARTY-NOTICES.txt - nothing else enforces this.
export default defineConfig({
entry: "src/index.ts",
format: ["esm", "cjs"],
Expand Down