-
Notifications
You must be signed in to change notification settings - Fork 34
Home
pegli edited this page Apr 18, 2012
·
22 revisions
To learn more about TouchDB, the underlying implementation of this module, see the TouchDB-iOS Wiki.
TiTouchDB requires that the TouchDB and TouchDBListener frameworks are installed at build time.
- Grab the module zip file from the Downloads section and place it in your Titanium folder (usually ~/Library/Application Support/Titanium).
- Get the latest prebuilt TouchDB libraries from the TouchDB Downloads page.
- Extract the TouchDB zip file and cd to the iOS folder.
- Copy TouchDB.framework and TouchDBListener.framework to ~/Library/Frameworks, creating that folder if necessary.
Here's how to load up the module and get a database object:
var TiTouchDB = require('com.obscure.TiTouchDB');
var db = TiTouchDB.databaseNamed('books');
db.ensureCreated();
See the API documentation and TouchBooks sample for more information.