dist/index.js
function offChildAdded(dbRef, dataToCache) {
		var storageKey = getStorageKeyFromDbRef(dbRef, 'child_added');

		//Turn listener off.
		dbRef.off();

		return new Promise(function (resolve, reject) {
			resolve(_reactNative.AsyncStorage.setItem(storageKey, JSON.stringify(dataToCache)));
		});
	}
function offChildAdded(dbRef, dataToCache) {
		var storageKey = getStorageKeyFromDbRef(dbRef, 'child_added');

		//Turn listener off.
		dbRef.off();

		return new Promise(function (resolve, reject) {
			resolve(_reactNative.AsyncStorage.setItem(storageKey, JSON.stringify(dataToCache)));
		});
	}
function offChildAdded ( dbRef , dataToCache ) { var storageKey = getStorageKeyFromDbRef ( dbRef , 'child_added' ) ; //Turn listener off. dbRef . off ( ) ; return new Promise ( function ( resolve , reject ) { resolve ( _reactNative . AsyncStorage . setItem ( storageKey , JSON . stringify ( dataToCache ) ) ) ; } ) ; }
Turn off listeners at a certain database.Reference, and cache the data passed in so that it can be passed to a new "child_added" listener if one is created.
@param {*} dbRef Reference to stop listening at.
@param {*} dataToCache Data that should be cached for this location. Tip: [].slice(-20) to keep the latest 20 items.
Turn off listeners at a certain database . Reference and cache the data passed in so that it can be passed to a new child_added listener if one is created .