Closed le0pard closed 9 years ago
I tried to reproduce this error (in a Chrome App) without success.
1) Does the error still happen if you use lovefield.min.js? 2) At line 4043 in your screenshot, there is a goog.provide('goog.debug.Error') which should be creating the goog.debug namespace, such that this error is not thrown. Is there something in your overall setup that would prevent that call from working correctly (Maybe you have a global COMPILED = true variable somewhere else in your code?)
Hello @freshp86 .
With "lovefield.min.js" I don't have such error, but code little different:
'use strict';
import lovefield from '../../../../../node_modules/lovefield/dist/lovefield.min.js';
import logger from '../../utils/logger.js.es6';
class IndexedStorageDB {
constructor() {
this.schemaBuilder = lovefield.lf.schema.create('cloud-database', 1);
this.schemaBuilder.createTable('accounts').
addColumn('id', lovefield.lf.Type.INTEGER).
addColumn('type', lovefield.lf.Type.STRING).
addColumn('title', lovefield.lf.Type.STRING).
addColumn('provider_key', lovefield.lf.Type.STRING).
addColumn('provider_secret', lovefield.lf.Type.STRING).
addColumn('is_default', lovefield.lf.Type.BOOLEAN).
addPrimaryKey(['id']).
addIndex('idxType', ['type'], false, lovefield.lf.Order.ASC);
}
loadAccounts() {
logger.debug('load accounts');
}
}
export default IndexedStorageDB;
Thanks!
Trying to use in Chrome App. Get error: "Uncaught TypeError: Cannot set property 'Error' of undefined".
Screenshot: http://take.ms/NKjho
Tools:
grunt v0.4.5 browserify v10.1.3 lovefield v2.0.50
Example of code: