File '.../node_modules/wa-sqlite/src/types/sqlite-api.d.ts' is not a module.
The dist file etc are also not typed, import SQLiteAsyncESMFactory from "wa-sqlite/dist/wa-sqlite-async.mjs"; throws a type error, as does import * as VFS from "wa-sqlite/src/VFS";
The text was updated successfully, but these errors were encountered:
Hmm. I don't write in Typescript. I added the declaration file because it was the easiest way to generate documentation and provide VSCode Intellisense hints (for Javascript).
It looks like you can at least compile by using a local Javascript file to import from the package and then import that Javascript into Typescript. But that's horrible because all the API signatures are lost.
I haven't found great Typescript documentation for what I'm trying to do so I haven't figured out how to fix this, but I'll keep poking at it.
You can't import the main api via
import * as SQLite from "wa-sqlite";
because it throws this error:
File '.../node_modules/wa-sqlite/src/types/sqlite-api.d.ts' is not a module.
The dist file etc are also not typed,
import SQLiteAsyncESMFactory from "wa-sqlite/dist/wa-sqlite-async.mjs";throws a type error, as doesimport * as VFS from "wa-sqlite/src/VFS";The text was updated successfully, but these errors were encountered: