use import/export in the frontend code

This commit is contained in:
Danny Coates 2017-08-10 10:02:13 -07:00
parent 11ae7f857c
commit 702134b3b1
No known key found for this signature in database
GPG key ID: 4C442633C62E00CB
15 changed files with 51 additions and 64 deletions

View file

@ -1,4 +1,4 @@
const { isFile } = require('./utils');
import { isFile } from './utils';
class Mem {
constructor() {
@ -26,7 +26,7 @@ class Mem {
}
}
class Storage {
export default class Storage {
constructor() {
try {
this.engine = localStorage || new Mem();
@ -97,5 +97,3 @@ class Storage {
this.engine.setItem(id, JSON.stringify(file));
}
}
module.exports = Storage;