cheerp-meta
                                
                                
                                
                                    cheerp-meta copied to clipboard
                            
                            
                            
                        Add support for the second edition of the IndexedDB API
The IndexedDB API has a second edition which supports some new methods like IDBObjectStore.getAllKeys(). It would be nice if Cheerp exposed these new methods.
Thanks for reporting this, we will add support for this in the next release. In general you should be able to extend Cheerp to currently non stock supported API by declaring the appropriate classes in the client namespace. See https://github.com/leaningtech/cheerp-meta/wiki/Browser-side-programming-guide#accessing-the-dom-under-the-hood for an example.
In this case, the new functionality is not a new class, but a new method of an existing class (IDBObjectStore). Is that still something I can declare myself?
You should be able to derive a new class from the original one and access the new method by pointer casting.
Thanks, that works!
I assume I should keep the report open to track Cheerp adding support for it directly.
IDBObjectStore.getAllKeys() was added in https://github.com/leaningtech/cheerp-utils/commit/71a1a5411b678dfaaebef354de71ab3cafe98bae