yathit / ydn-db

Javascript database module for Indexeddb, Web SQL and localStorage storage mechanisms supporting version migration, advanced query, SQL and transaction.
Apache License 2.0
503 stars 41 forks source link

no example of how to use ydn.dB module in browserify bundled project #93

Closed kiddhustle closed 8 years ago

kiddhustle commented 8 years ago

The ydn.dB module is packaged as closure library module. This doesn't seem to be compatible with browserify which uses CommonJs.

A working example in the docs would be helpful.

yathit commented 8 years ago

Sorry, we do not have example. All of our projects use raw js code with closure library.

If you use closure compiler, it supports CommonJS module.

kiddhustle commented 8 years ago

OK I think figured it out. Simply requiring the module (and not assigning it to a variable )will make it global inside the module that you're requiring it from.

Thanks for the response all the same.