Closed mcfarljw closed 10 years ago
Currently this is not supported in IE10 and IE 11. As a workaround you can stringify and use that as a key.
Please read the below threads for more information:
http://stackoverflow.com/questions/14283257/indexeddb-compound-key-ie10
I was afraid of that. I ended up just combined the two keys into a string, but either or it's not a jquery-indexeddb issue.
When I use the following it works in Chrome and Firefox, but cases issues in the latest version of IE.
transaction.createObjectStore('products', {keyPath: ['name', 'revision']});
First it throws a "DataError" at: https://github.com/axemclion/jquery-indexeddb/blob/ed5507cd49ee93fbdec449341306b81507db8f41/dist/jquery.indexeddb.js#L134
Followed by "Assignment to read-only properties is not allowed in strict mode" at: https://github.com/axemclion/jquery-indexeddb/blob/ed5507cd49ee93fbdec449341306b81507db8f41/dist/jquery.indexeddb.js#L90
When I dumb down the keyPaths two a sing single rathe than array it appears to work. Any thoughts on why this might be happening only in IE?