Skip to content

Releases: 1999/sklad

4.1.1

17 Mar 15:17
Compare
Choose a tag to compare
  • broken get operations within multiple stores fixed

4.1.0

08 Mar 14:55
Compare
Choose a tag to compare

Get operations are now using IDBObjectStore.prototype.getAll internally in all browsers which support this API. Currently these browsers are stable Chromium-based and Firefox. This API is activated when you run fetch operations without index and special direction (e.g. when only limit, offset or range are specified). JSPerf test shows that you get 200%-1000% speed increase for your get operations when using this API, so it's time to update sklad to this version 😃

4.0.0

05 Mar 09:54
Compare
Choose a tag to compare

A huge work has been done to support library in all major browsers. Now Sklad supports stable versions of Chrome, Firefox, IE11 in Win8/10, Microsoft Edge, Safari9 desktop/mobile and Android browser. All tests run in SauceLabs platform for continuous integration through TravisCI. Special thanks goes to Paul Kilmurray, you're the man!

Short list of changes:

  • breaking change: promises now reject with Error instances, not DOMError. The reason for this is that interface is supported only in Firefox/Chrome. If you checked name field of err to understand what kind of error occured, nothing changes for you (related commit)
  • new: support for IE11 and Microsoft Edge introduced
  • new: support for Safari9 introduced
  • new: support for Firefox introduced
  • I got rid of separate Makefile and now all targets are described inside package.json which is more natural to Javascript project (related commit)

Check this PR if you want to see all changes: https://github.com/1999/sklad/pull/15/files

IE support

sklad is now working in IE11 and Microsoft Edge browsers. Still there is one browser bug which cannot be fixed inside library: both IE11 and Edge don't support multiEntry indexes (more info). Other library features like working with data, upgrading database and others work as expected. An absence of autoIncrement field in IDBObjectStore (both IE11 and Edge) is patched inside library (related commit, bug).

IE11 is missing support for native Promise, so you should add some. I was using promise-polyfill inside my tests mostly because it's simple and doesn't replace native Promise with its own implementation.

Safari9 support

Safari8 IndexedDB implementation is buggy and is not available to be replaced/shimmed with indexeddbshim so I had to give up on its support. Still IndexedDB implementation in Safari9 is quite okay and sklad is now working in these browsers (desktop/mobile). Still there are some browser bugs which you should keep in mind:

  • Safari doesn't throw ConstraintErrors for unique keys (link, test)
  • Safari doesn't expose existing indexes in 2+ upgradeneeded (link). So you can't use indexNames of object store inside versionchange transaction.

Safari also fails to work with multiple object stores inside one transaction, but I made a patch for this inside sklad library (related commit).

Firefox support

Tests are now passing in Firefox.

3.0.0

19 Jan 06:34
Compare
Choose a tag to compare
  • Sklad is now built with Webpack. Library code is now transpiled from ES2015 into ES5 which leads to some overhead. New release has new major version only for safety reasons: no new changes are introduced, all tests passed 😃

2.0.0

15 Oct 21:13
Compare
Choose a tag to compare
  • new: promises support added
  • breaking change: old node-style API is now used only in 1.x branch releases

1.3.0

28 Jun 19:19
Compare
Choose a tag to compare
  • insert, delete, upsert and clear methods don't fail if no callbck is supplied (#10)

1.2.0

21 Oct 18:43
Compare
Choose a tag to compare
  • new: this in migration scripts now refers to IDBOpenDBRequest so that you can create indexes on top of already created object stores. Check out docs for more info.

1.1.0

16 Oct 04:11
Compare
Choose a tag to compare
  • new: sklad.deleteDatabase() method

1.0.0

14 Oct 04:26
Compare
Choose a tag to compare
  • new: full tests coverage with Travis CI: Travis CI, tests
  • new: CommonJS module syntax support
  • new: skladConnection.close() method to explicitly close existing connection (#3)
  • new: semver support
  • new: blocked event support with InvalidStateError DOMError
  • fix: callbacks with errors could run more than once
  • fix: external docs page contains close to truth examples (#2)
  • breaking change: callbacks are now invoked with DOMError instance as a first argument if error happens during operation, previously it could be either String or Error. Check out docs for examples.
  • breaking change: skladConnection.get() invokes callback with not objects but array with objects with key and value keys (details). Previously it was an object and this was a design error.

There's also a short migration guide here.

0.2.1

21 Oct 20:27
Compare
Choose a tag to compare
  • new: AMD module syntax support