hunk.code_window:         else {
               const database: Uint8Array = this.databaseConnection.export();
               // convert Uint8Array to number array to improve local-storage storage
               const databaseArray = [].slice.call(database);
               PlatformTools.getGlobalVariable().localStorage.setItem(path, JSON.stringify(databaseArray));
           }
       }
  
hunk.labels: keep keep keep keep replace keep keep keep
hunk.after_edit:             if (this.options.useLocalforage) {
                   if (window.localforage) {
                       await window.localforage.setItem(path, JSON.stringify(databaseArray));
                   } else {
                       throw new Error(`localforage is not defined - please import localforage.js into your site`);
                   }
               } else {
                   PlatformTools.getGlobalVariable().localStorage.setItem(path, JSON.stringify(databaseArray));
               }
  
hunk.file_path: src/driver/sqljs/SqljsDriver.ts
hunk.type: replace
file: import {Entity, PrimaryColumn} from "../../../../src";
  import {ManyToMany} from "../../../../src/decorator/relations/ManyToMany";
  import {Post} from "./Post";
  
  @Entity()
  export class Category {
  
      @PrimaryColumn({ collation: "ascii_general_ci", charset: "ascii" })
      id: string;
  
      @ManyToMany(type => Post, post => post.categories)
      posts: Post[];
  
  }