tw-plugin-rollup 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -196,7 +196,7 @@ Details:
|
|
|
196
196
|
## Notes & caveats
|
|
197
197
|
|
|
198
198
|
- **One file only.** TurboWarp loads a single `<script>`, so don't use dynamic `import()` / code splitting — keep it one synchronous bundle. The plugin sets `output.inlineDynamicImports` to enforce a single chunk.
|
|
199
|
-
- **`Scratch` is a global**, not an import. Your editor/linter may flag it; declare it as a readonly global (e.g. in ESLint `languageOptions.globals`). For TypeScript, [`@turbowarp/types`](https://github.com/TurboWarp/types) provides the `Scratch` typings.
|
|
199
|
+
- **`Scratch` is a global**, not an import. Your editor/linter may flag it; declare it as a readonly global (e.g. in ESLint `languageOptions.globals`). For TypeScript, [`@turbowarp/types`](https://github.com/TurboWarp/types) provides the `Scratch` typings for **Scratch** extensions. If you're targeting **TurboWarp or one of its forks**, use [`types-tw`](https://github.com/TurboWarp/types-tw) instead, which adds the TurboWarp-specific APIs. It's no longer published to npm, so install it from git — it keeps the `@turbowarp/types` package name as a drop-in replacement: `npm install @turbowarp/types@git+https://github.com/TurboWarp/types-tw.git#tw`.
|
|
200
200
|
- **Source maps:** prefer `sourcemap: false`. A trailing `//# sourceMappingURL=` comment would otherwise sit in the middle of the wrapped file. (When sourcemaps are on, the plugin uses `magic-string` to keep the mapping correct across the wrapper.)
|
|
201
201
|
|
|
202
202
|
## Is a plugin the best way to do this?
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tw-plugin-rollup",
|
|
3
3
|
"description": "Bundle a multi-file TurboWarp/Scratch extension into a single unsandboxed-extension file with Rollup, Rolldown, or Vite.",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.2",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MPL-2.0",
|
|
7
7
|
"author": "playforge-coding",
|