lindera-wasm-web 3.0.1 → 3.0.3

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.
Binary file
package/opfs.js CHANGED
@@ -175,15 +175,16 @@ async function extractZip(zipBuffer) {
175
175
  * @param {object} [options] - Optional settings.
176
176
  * @param {function} [options.onProgress] - Progress callback receiving
177
177
  * `{ phase: string, loaded?: number, total?: number }`.
178
+ * @param {RequestInit} [options.fetchInit] - Additional options passed to `fetch()`.
178
179
  * @returns {Promise<void>}
179
180
  * @throws {Error} If download fails, archive is invalid, or required files are missing.
180
181
  */
181
182
  export async function downloadDictionary(url, name, options = {}) {
182
- const { onProgress } = options;
183
+ const { onProgress, fetchInit = {} } = options;
183
184
 
184
185
  // Download
185
186
  if (onProgress) onProgress({ phase: "downloading" });
186
- const response = await fetch(url);
187
+ const response = await fetch(url, fetchInit);
187
188
  if (!response.ok) {
188
189
  throw new Error(`Failed to download dictionary: HTTP ${response.status}`);
189
190
  }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "lindera-wasm-web",
3
3
  "type": "module",
4
4
  "description": "Lindera WASM (web target)",
5
- "version": "3.0.1",
5
+ "version": "3.0.3",
6
6
  "license": "MIT",
7
7
  "repository": {
8
8
  "type": "git",