How do I import the Dart IndexedDB library in Flutter?

729

According to this issue: indexedDB blocked

indexedDB is blocked in flutter

you could use an alternative like idb_shim which is simply a wrapper for indexedDB API

Share:
729
Tusshu
Author by

Tusshu

Updated on December 29, 2022

Comments

  • Tusshu
    Tusshu over 1 year

    I am using following statement to import dart indexed db library in Flutter application:

    import 'dart:indexed_db';
    

    VSCode reports following error:

    Target of URI doesn't exist: 'dart:indexeddb'.
    Try creating the file referenced by the URI, or Try using a URI for a file that does 
    exist.dart(uri_does_not_exist)
    

    How to use indexed db in Flutter?

  • Tusshu
    Tusshu about 3 years
    Thanks. Used sembast_web: ^2.0.0+2