{"_id":"@dashevo/dapi-db-counterstore","_rev":"18-7b25d9c241bd67d63aca4430f7238b70","name":"@dashevo/dapi-db-counterstore","dist-tags":{"latest":"1.4.2"},"versions":{"1.4.0":{"name":"@dashevo/dapi-db-counterstore","version":"1.4.0","author":{"name":"Haad"},"license":"MIT","_id":"@dashevo/dapi-db-counterstore@1.4.0","maintainers":[{"name":"alex-werner","email":"alex@werner.fr"},{"name":"andyfreer","email":"andy@dash.org"},{"name":"antouhou","email":"antouhou@gmail.com"},{"name":"cofresi","email":"cofresi@dash.org"},{"name":"dreyacosta","email":"david.rey.acosta@gmail.com"},{"name":"kamuela","email":"kamuela.franco@gmail.com"},{"name":"nmarley","email":"nathan.marley@gmail.com"},{"name":"pierrevr","email":"pierre@dash.org"},{"name":"seigler","email":"joshua@seigler.net"},{"name":"shumkov","email":"ivan@shumkov.ru"},{"name":"snogcel","email":"ledniknoj@gmail.com"}],"dist":{"shasum":"605f6c642fb33a84cea3fa07a1e1b97a45153137","tarball":"https://registry.npmjs.org/@dashevo/dapi-db-counterstore/-/dapi-db-counterstore-1.4.0.tgz","fileCount":10,"integrity":"sha512-LHCJ5Az/REVllQgwfd0phvvIDhgMJHBzpz5Ar/uLL9MVzPqhKnSJZqiPcNZ7BPLbLAqxJubA6my0WavKxymBKQ==","signatures":[{"sig":"MEUCIARVvALZPlXySeMZsAFzB0L61vEYZwCcSvMy0hvRGkzbAiEAmE++J4z58es+YR7A2LZGaFKiEaGIn5te6a1/wQoQOfE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1268348,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbGxBYCRA9TVsSAnZWagAAeUoP/2vn7XhUGLgV8VNFpBQX\nKfupn5tja1vpLbiGeDBtLCy7ICVNJ260fd8AWOHXIxGM6kf3+0fFARCjNMYp\nz/Q5V3DqMPQK6W4kPrwM6ZcoUNkZNYRuqxWLjsnMnucfWVjhHOHOo0gGPe9L\n6X7U0+V24RWEegh2+KmgKRZdJloosRdxcymkAtrwt+wpbn1b7cbvCweDzS0a\ndILYl34SLeScsykJEp8ohVflw9orQBw48lEd+VykMT4MbCMSZcgD9suxapAo\n3bCRK6GEqeQHlXiusMzXmu327vua0cic+WhUfe446ykB3AWJ2aSQVYXfk1KB\nzQH3U+WmApBJGUBxzIB/lBDnW/SLZAQQVHUE5l62ZxbcQ8xd/6Yf7E18rCAd\n8b/jFAx4HUn0RpBMUtqdsB15J1nwvOVOwAeYnA2uuj7Eug3ZPwC61u85FkdG\n/pi+a6TZmcjvJclsxouov8lBnuABVz/rIsrX23ti4iTKgA9l77BPzmKaUb9f\nxCBJpFNMPJ5baZL27Z0iYc0dG725enMMoMqomPvS3T+lezZg34+uFwIkkkZI\nSkwlcZS6HYneO5X/O6YDrL6XR0W2auyvhgLTTwCvvPOR0uQdqNtAgzTBBXTe\nKDsxaP8iRBftkBF80GSX90YnDCvUk2Kojdc1bqUMt/htLoDLijtJDqTWcJpU\nKrlU\r\n=CJ3u\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/CounterStore.js","gitHead":"cccd3bbc610484192bbe154df15c33c9a5bba98d","scripts":{"lint":"eslint .","lint:fix":"eslint . --fix"},"_npmUser":{"name":"cofresi","email":"cofresi@dash.org"},"_npmVersion":"5.6.0","description":"Counter store for dapi-db","directories":{},"_nodeVersion":"9.5.0","dependencies":{"crdts":"~0.1.2","@dashevo/dapi-db-store":"~2.5.1"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^4.19.1","eslint-plugin-import":"^2.12.0","eslint-config-airbnb-base":"^12.1.0"},"_npmOperationalInternal":{"tmp":"tmp/dapi-db-counterstore_1.4.0_1528500312246_0.9266966967770165","host":"s3://npm-registry-packages"}},"1.4.1":{"name":"@dashevo/dapi-db-counterstore","version":"1.4.1","author":{"name":"Haad"},"license":"MIT","_id":"@dashevo/dapi-db-counterstore@1.4.1","maintainers":[{"name":"alex-werner","email":"alex@werner.fr"},{"name":"andyfreer","email":"andy@dash.org"},{"name":"antouhou","email":"antouhou@gmail.com"},{"name":"cofresi","email":"cofresi@dash.org"},{"name":"dreyacosta","email":"david.rey.acosta@gmail.com"},{"name":"kamuela","email":"kamuela.franco@gmail.com"},{"name":"nmarley","email":"nathan.marley@gmail.com"},{"name":"pierrevr","email":"pierre@dash.org"},{"name":"seigler","email":"joshua@seigler.net"},{"name":"shumkov","email":"ivan@shumkov.ru"},{"name":"snogcel","email":"ledniknoj@gmail.com"}],"dist":{"shasum":"40b67f496a3894077a625f071256d573e1ea6342","tarball":"https://registry.npmjs.org/@dashevo/dapi-db-counterstore/-/dapi-db-counterstore-1.4.1.tgz","fileCount":10,"integrity":"sha512-/j06VQPhKkeKxkVJLNcytGDJGo+VTCAFOOpfVUHpVpsRz2C5G8Ln9vWYL+4PTD09HhY7+FcWxrbADFB5jTF2xA==","signatures":[{"sig":"MEYCIQDrdDLILoFVg478YIobH5Te6riQyDKG7WiVy8QcdivviwIhAKtnfKO6yIGx2QhB1AuICrFNKwN+HAGc7ipi09lf4Xb/","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1268348,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbGxCuCRA9TVsSAnZWagAAcZgP/2e/Iez0Y6/OgOtkvVYF\nw+qcjuv8aXuz5equiFsC+CCqg3fIXteXUAYyFNp4Ww7jSVFjx5evs6a8G/vi\nLoWnAJ0vEjjaU6rqrLQTLQKcVk3enicwcBETfkOFLpJ4cGKgqwBdqY157dqF\nJKxRUX8mW5v1pPfx9x361Vq0iYPezbcWYYGxrjdrjsPoSIaQDukZoC0NcTLl\n55kyNylorDRxJ16/Wui171uM3UBJQurReq7CFi8SBdAZKmXaCXi8l8gD3Srr\nc5rNPNgiBTJlVMYLyQWo8U9oawTVrttmiITNgnCFjeowxDsnsrh7q3j0h5Vj\nL+4FlQpsmzm4yN8lF8qxWFEYG+4UmOflmaKhk5izC7suQnYsmk4raQrL2iZU\nz8FWmOxvkTmKecKgLPuCrtImiNgKfjQsVNT0ajT8lrssvQeidWnN2Fh1mA7p\ndgL2Y46YZuWGwSFpkwB2LohwZv3Yl/8+e+bbjhtAWgW77n6NQLDLCg/7gtL7\nM8OxP9RhvVYJmQOUvSAiMxYSKuPx3DEJ5XM4A60HEfD8Dew4BCul2S67n+zE\nsFVPu6tui8+5m5Qen6Cx/SVB3F6jeLF6KhS4fsclqlWrkV+RxSsqIG157Lb+\nu1i9FfhzpkgitrK246AozlSzVwsWIHQSwI1LRcrj3ecDLIVSTLvTzpiRaM4T\nsPgW\r\n=CGGK\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/CounterStore.js","gitHead":"ef4af960b6a59446f036e03f5342ffb7e71129fa","scripts":{"lint":"eslint .","lint:fix":"eslint . --fix"},"_npmUser":{"name":"cofresi","email":"cofresi@dash.org"},"_npmVersion":"5.6.0","description":"Counter store for dapi-db","directories":{},"_nodeVersion":"9.5.0","dependencies":{"crdts":"~0.1.2","@dashevo/dapi-db-store":"~2.5.1"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^4.19.1","eslint-plugin-import":"^2.12.0","eslint-config-airbnb-base":"^12.1.0"},"_npmOperationalInternal":{"tmp":"tmp/dapi-db-counterstore_1.4.1_1528500397978_0.050116844174703745","host":"s3://npm-registry-packages"}},"1.4.2":{"name":"@dashevo/dapi-db-counterstore","version":"1.4.2","author":{"name":"Haad"},"license":"MIT","_id":"@dashevo/dapi-db-counterstore@1.4.2","maintainers":[{"name":"alex-werner","email":"alex@werner.fr"},{"name":"andyfreer","email":"andy@dash.org"},{"name":"antouhou","email":"antouhou@gmail.com"},{"name":"cofresi","email":"cofresi@dash.org"},{"name":"dreyacosta","email":"david.rey.acosta@gmail.com"},{"name":"evodeploy","email":"evodeploy@blackcarrot.be"},{"name":"kamuela","email":"kamuela.franco@gmail.com"},{"name":"nmarley","email":"nathan.marley@gmail.com"},{"name":"pierrevr","email":"pierre@dash.org"},{"name":"seigler","email":"joshua@seigler.net"},{"name":"shumkov","email":"ivan@shumkov.ru"},{"name":"snogcel","email":"ledniknoj@gmail.com"}],"dist":{"shasum":"c220fa00d13d20ca88fef0af8f2f2be6b6dd621e","tarball":"https://registry.npmjs.org/@dashevo/dapi-db-counterstore/-/dapi-db-counterstore-1.4.2.tgz","fileCount":10,"integrity":"sha512-dJG6TIrVtNQgQ4Lmk1UwKEckPrWeWiX9u61/EmKvkrsJoiZW1RZjXu9Ct/lqtShuFFYTbhwnsuii3VeP4mBMkQ==","signatures":[{"sig":"MEYCIQCw8pLUfQtAamwjKiG5Y9R9HZvoOHjRsa99PcP8SOK+sAIhAP/BvOkPsuUQ+nySGHWStRkLsGz3Gs7AsLmuBsfMilXN","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":1268502,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJb6fKmCRA9TVsSAnZWagAA5X0P/iWRxPnlsHv2m6XwJnpy\ntVvrLw7rUeXBk5zCx4Bynva7/+eMY8XPl6KzRSEFKFxUp2T2y58EeLxDWeXM\nx9sc8Op4FidtEs80eChAbdAPuCPCAXY/QUhRt3znZ0QhCovZkQjb7xckLVop\nZqi6zpsx8hd+TlzmYOR70C8TTm/qNj55FcWlkoUed5rudB4pPpWQDK0QAxvy\nJ6vAemyC47rasKAFc9rCmA7C/rNAuLdqyWz5wOU1FcCzSwZukOEnR7pC/2Gy\nByiC+a8FBChWXul8u3QmyQ0z7zPGj9FL1oI5/96fEtnNznmn51o4vGefY1Ff\nxdP7s4g2bZThv0+MzB73cpflJyYrgXVbWEmVkgIDq4eTSQMHIyznInpDjenz\nBItRpDXsBiFRNdqdg65AtUA6JQ5ky5GPh76iooQ2TqBMjblPoC4ulSZc0GrX\npv/JajhhqkoNLmneu1dDsj3QwArjZ2Hs2zM3mBOx+5pFPfZ/qtx2dbQoB9TG\nZovxUCDkdZ6sigfKOB5ht09WNwQE9TK1cCOL6pPsucorjW870nYEO1IWQx/m\n+6p+Ef/EIG5vxYc69EpBYLmjnaUqfncauCZJmnuS9syV3vUp2uV89w4HpbrN\nhFRfOJ4uhqX2Kc7klIYavz7AjuH14hfAEoLugttwwQLjWYeEMJNOzbmELKWN\nMrDX\r\n=eM88\r\n-----END PGP SIGNATURE-----\r\n"},"main":"src/CounterStore.js","gitHead":"fd3b814e955bda36408c3e3d6b6a5d73b9468957","scripts":{"lint":"eslint .","lint:fix":"eslint . --fix"},"_npmUser":{"name":"cofresi","email":"cofresi@dash.org"},"_npmVersion":"6.4.1","description":"Counter store for dapi-db","directories":{},"_nodeVersion":"8.9.3","dependencies":{"crdts":"~0.1.2","@dashevo/dapi-db-store":"~2.5.3"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^4.19.1","eslint-plugin-import":"^2.12.0","eslint-config-airbnb-base":"^12.1.0"},"_npmOperationalInternal":{"tmp":"tmp/dapi-db-counterstore_1.4.2_1542058661933_0.1613473436533741","host":"s3://npm-registry-packages"}}},"time":{"created":"2018-06-08T23:25:12.070Z","modified":"2026-01-20T16:36:10.677Z","1.4.0":"2018-06-08T23:25:12.316Z","1.4.1":"2018-06-08T23:26:38.262Z","1.4.2":"2018-11-12T21:37:42.150Z"},"author":{"name":"Haad"},"license":"MIT","description":"Counter store for dapi-db","maintainers":[{"email":"ivan@shumkov.ru","name":"shumkov"},{"email":"obusco@gmail.com","name":"alex-werner"},{"email":"nathan.marley@gmail.com","name":"nmarley"},{"email":"cofresi@dash.org","name":"cofresi"},{"email":"evodeploy@blackcarrot.be","name":"evodeploy"},{"email":"djavidoff@gmail.com","name":"jawid-h"}],"readme":"# orbit-db-counterstore\n\n[![npm version](https://badge.fury.io/js/orbit-db-counterstore.svg)](https://badge.fury.io/js/orbit-db-counterstore)\n\nA simple counters database. Useful for example counting events separate from data.\n\nUsed in [orbit-db](https://github.com/haadcode/orbit-db).\n\n## Table of Contents\n\n- [Install](#install)\n- [Usage](#usage)\n- [API](#api)\n- [Contributing](#contributing)\n- [License](#license)\n\n## Install\n```\nnpm install orbit-db ipfs\n```\n\n## Usage\n\nFirst, create an instance of OrbitDB:\n\n```javascript\nconst IPFS = require('ipfs')\nconst OrbitDB = require('orbit-db')\n\nconst ipfs = new IPFS()\nconst orbitdb = new OrbitDB(ipfs)\n```\n\nGet a log database and add an entry to it:\n\n```javascript\nconst counter = orbitdb.counter('visitors')\ncounter.inc()\nconsole.log(counter.value)\n// 1\ncounter.inc(4)\nconsole.log(counter.value)\n// 5\n```\n\nLater, when the database contains data, load the history and query when ready:\n\n```javascript\nconst counter = orbitdb.counter('visitors')\ncounter.events.on('ready', () => {\n  counter.inc()\n  console.log(counter.value)\n  // 6\n})\n```\n\nSee [example/index.html](https://github.com/haadcode/orbit-db-counterstore/blob/master/example/index.html) for a detailed example. Note that to run this example, you need to have a local [IPFS daemon](https://dist.ipfs.io/go-ipfs/floodsub-2) [running](https://ipfs.io/docs/getting-started/) at port 5001.\n\n## API\n\nSee [orbit-db's API Documenations](https://github.com/haadcode/orbit-db/blob/master/API.md#countername) for full details.\n\n## Contributing\n\nSee [orbit-db's contributing guideline](https://github.com/haadcode/orbit-db#contributing).\n\n## License\n\n[MIT](LICENSE) © 2016-2018 Protocol Labs Inc., Haja Networks Oy, 2018 Dash Core Group, Inc.\n","readmeFilename":"README.md"}