konsoletyper / teavm

Compiles Java bytecode to JavaScript, WebAssembly and C
https://teavm.org
Apache License 2.0
2.55k stars 260 forks source link

Issue with indexed db on latest dev version. #914

Closed HoosierTransfer closed 1 month ago

HoosierTransfer commented 1 month ago

Method org.teavm.jso.indexeddb.IDBIndex.unwrapStringArray(Lorg/teavm/jso/JSObject;)[Ljava/lang/String; is marked with @JSByRef, but does not return valid array type at org.teavm.jso.indexeddb.IDBIndex.getKeyPath(IDBIndex.java:36) Method org.teavm.jso.indexeddb.IDBIndex.unwrapStringArray(Lorg/teavm/jso/JSObject;)[Ljava/lang/String; is marked with @JSByRef, but does not return valid array type at org.teavm.jso.indexeddb.IDBIndex.getKeyPath$static(IDBIndex.java:36)

I'm not sure what part of my code causes this error.

konsoletyper commented 1 month ago

It's an issue in IndexedDB declarations within TeaVM. The best way to work-around it is to copy these declaration sources into your project and fix them.

konsoletyper commented 1 month ago

See https://github.com/konsoletyper/teavm/tree/master/jso/apis/src/main/java/org/teavm/jso/indexeddb