{"_id":"@asset-pipe/sink-mem","_rev":"6-fa14c33e1b382e7940782d9254b9a7e6","name":"@asset-pipe/sink-mem","description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","dist-tags":{"latest":"1.1.3"},"versions":{"1.0.0":{"name":"@asset-pipe/sink-mem","version":"1.0.0","author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","main":"./lib/sink.js","repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"keywords":["test"],"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"}],"engines":{"node":">=8"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","publishConfig":{"access":"public"},"dependencies":{"JSONStream":"1.3.1","asset-pipe-common":"1.0.0-beta.6","readable-stream":"2.3.3","concat-stream":"1.6.0"},"devDependencies":{"commitizen":"^2.9.6","cz-conventional-changelog":"^2.1.0","eslint":"^4.10.0","eslint-config-finn":"^3.0.0","eslint-config-finn-prettier":"^3.0.1","jest":"^21.2.1","prettier":"^1.8.1","tap":"10.7.2","husky":"^0.14.3","semantic-release":"^8.2.0","lint-staged":"^4.3.0","projectz":"^1.4.0"},"scripts":{"semantic-release":"semantic-release pre && npm publish && semantic-release post","lint":"eslint .","test":"jest --coverage","lint:format":"eslint --fix .","precommit":"lint-staged","cm":"git-cz","readme":"projectz compile"},"files":["lib"],"jest":{"clearMocks":true,"coverageThreshold":{"global":{"branches":66,"functions":81,"lines":94,"statements":94}},"testEnvironment":"node"},"lint-staged":{"*.js":["eslint --fix --config ./.eslintrc","git add"],"{package.json,README.md,LICENSE.md}":["projectz compile","git add"]},"config":{"commitizen":{"path":"cz-conventional-changelog"}},"badges":{"list":["travisci","npmversion","daviddm","daviddmdev"]},"maintainers":[],"gitHead":"939afd9106c7e4ac7ccf0a0799792133fee420e9","homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","_id":"@asset-pipe/sink-mem@1.0.0","_npmVersion":"5.5.1","_nodeVersion":"8.9.0","_npmUser":{"name":"sveisvei","email":"sveinung.rosaker@gmail.com"},"dist":{"integrity":"sha512-uMtXjZnjkn1qbvdhqwH8Uv0Efe93n/z/s+nvmgN2p+5dtPRyCCtyTwPXgGxjZ9HIR/SQ/EiL7+FPiV1BxFo6hQ==","shasum":"ec02e2d8a394ab2fc466aace02b98b09b7a4e7d5","tarball":"https://registry.npmjs.org/@asset-pipe/sink-mem/-/sink-mem-1.0.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDZIXmf3l9pE8JB70fpvZM0tQKuLkHQBIOEA72Y0Ao9fQIgSd+jRq8Gptl870q2/vhgwlk6q9v/h8oZ6Mylew4k1eU="}]},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/sink-mem-1.0.0.tgz_1510323348063_0.17980037303641438"},"directories":{}},"1.1.0":{"name":"@asset-pipe/sink-mem","version":"1.1.0","author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","main":"./lib/sink.js","repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"keywords":["test"],"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"}],"engines":{"node":">=8"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","publishConfig":{"access":"public"},"dependencies":{"JSONStream":"1.3.1","asset-pipe-common":"1.0.0-beta.6","readable-stream":"2.3.3","concat-stream":"1.6.0"},"devDependencies":{"commitizen":"^2.9.6","cz-conventional-changelog":"^2.1.0","eslint":"^4.10.0","eslint-config-finn":"^3.0.0","eslint-config-finn-prettier":"^3.0.1","jest":"^21.2.1","prettier":"^1.8.1","tap":"10.7.2","husky":"^0.14.3","semantic-release":"^8.2.0","lint-staged":"^4.3.0","projectz":"^1.4.0"},"scripts":{"semantic-release":"semantic-release pre && npm publish && semantic-release post","lint":"eslint .","test":"jest --coverage","lint:format":"eslint --fix .","precommit":"lint-staged","cm":"git-cz","readme":"projectz compile"},"files":["lib"],"jest":{"clearMocks":true,"coverageThreshold":{"global":{"branches":66,"functions":81,"lines":94,"statements":94}},"testEnvironment":"node"},"lint-staged":{"*.js":["eslint --fix --config ./.eslintrc","git add"],"{package.json,README.md,LICENSE.md}":["projectz compile","git add"]},"config":{"commitizen":{"path":"cz-conventional-changelog"}},"badges":{"list":["travisci","npmversion","daviddm","daviddmdev"]},"maintainers":[{"name":"simenb","email":"sbekkhus91@gmail.com"},{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},{"name":"sveisvei","email":"sveinung.rosaker@gmail.com"},{"name":"trygve","email":"post@trygve-lie.com"}],"gitHead":"85c4a10de2ed312a61aff4999135f4bdc51345d7","homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","_id":"@asset-pipe/sink-mem@1.1.0","_npmVersion":"5.5.1","_nodeVersion":"9.2.0","_npmUser":{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},"dist":{"integrity":"sha512-YLkMxzO+DETFioz83maucyU5ZKiaGTmqpZpgWvWP5mbP+imjIfnGJsW0qEVE3EEpvAdGPmFTnEt8LPet80TNPw==","shasum":"6c58069afdf85e461e9e2fb665f995c1d4fd777f","tarball":"https://registry.npmjs.org/@asset-pipe/sink-mem/-/sink-mem-1.1.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCID6UeFfw8sL9IZLf9dvDarYmPHPf9ab1IFguI1mUfxztAiBvyuvrpO6UJsRpfWWMZCkHdW5rDZM8Lk2qWqVhSr+kJg=="}]},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/sink-mem-1.1.0.tgz_1510901776558_0.35421530273742974"},"directories":{}},"1.1.1":{"name":"@asset-pipe/sink-mem","version":"1.1.1","author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","main":"./lib/sink.js","repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"keywords":["test"],"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"}],"engines":{"node":">=8"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","publishConfig":{"access":"public"},"dependencies":{"JSONStream":"1.3.1","asset-pipe-common":"1.0.0-beta.6","readable-stream":"2.3.3","concat-stream":"1.6.0"},"devDependencies":{"commitizen":"^2.9.6","cz-conventional-changelog":"^2.1.0","eslint":"^4.10.0","eslint-config-finn":"^3.0.0","eslint-config-finn-prettier":"^3.0.1","jest":"^21.2.1","prettier":"^1.8.1","tap":"10.7.2","husky":"^0.14.3","semantic-release":"^8.2.0","lint-staged":"^4.3.0","projectz":"^1.4.0"},"scripts":{"semantic-release":"semantic-release pre && npm publish && semantic-release post","lint":"eslint .","test":"jest --coverage","lint:format":"eslint --fix .","precommit":"lint-staged","cm":"git-cz","readme":"projectz compile"},"files":["lib"],"jest":{"clearMocks":true,"coverageThreshold":{"global":{"branches":66,"functions":81,"lines":94,"statements":94}},"testEnvironment":"node"},"lint-staged":{"*.js":["eslint --fix --config ./.eslintrc","git add"],"{package.json,README.md,LICENSE.md}":["projectz compile","git add"]},"config":{"commitizen":{"path":"cz-conventional-changelog"}},"badges":{"list":["travisci","npmversion","daviddm","daviddmdev"]},"maintainers":[{"name":"simenb","email":"sbekkhus91@gmail.com"},{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},{"name":"sveisvei","email":"sveinung.rosaker@gmail.com"},{"name":"trygve","email":"post@trygve-lie.com"}],"gitHead":"b2ac72e6f9752c38be8a4e28c09754173450d137","homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","_id":"@asset-pipe/sink-mem@1.1.1","_npmVersion":"5.5.1","_nodeVersion":"9.2.0","_npmUser":{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},"dist":{"integrity":"sha512-pE8IG4uRex9WzZ+xpSeqQzdUrsV3Ka59r7YqqKbVJIw5fL/Ho4rRlMaLj6qt9BDWpa8ne5ShhnFxdsMqaNsNTA==","shasum":"6bf26605ec571269701a2471f7c8359ebe122fd6","tarball":"https://registry.npmjs.org/@asset-pipe/sink-mem/-/sink-mem-1.1.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDO/NAacl6opTJAGu8uOudtBZccHuMrFi+4BMY/3OxykAIhAPtjaGpyslvgy5/qfXQN+vG2QgSPe8EwVllBm1QHuVt3"}]},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/sink-mem-1.1.1.tgz_1510905639383_0.7577909394167364"},"directories":{}},"1.1.2":{"name":"@asset-pipe/sink-mem","version":"1.1.2","author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","main":"./lib/sink.js","repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"keywords":["test"],"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"}],"engines":{"node":">=8"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","publishConfig":{"access":"public"},"dependencies":{"JSONStream":"^1.3.1","asset-pipe-common":"^1.0.0-beta.6","boom":"^7.1.1","concat-stream":"^1.6.0","readable-stream":"^2.3.3"},"devDependencies":{"commitizen":"^2.9.6","cz-conventional-changelog":"^2.1.0","eslint":"^4.10.0","eslint-config-finn":"^3.0.0","eslint-config-finn-prettier":"^3.0.1","eslint-plugin-import":"^2.8.0","husky":"^0.14.3","jest":"^21.2.1","lint-staged":"^6.0.0","prettier":"^1.8.1","projectz":"^1.4.0","semantic-release":"^8.2.0","tap":"10.7.2"},"scripts":{"semantic-release":"semantic-release pre && npm publish && semantic-release post","lint":"eslint .","test":"jest --coverage","lint:format":"eslint --fix .","precommit":"lint-staged","cm":"git-cz","readme":"projectz compile"},"files":["lib"],"jest":{"clearMocks":true,"coverageThreshold":{"global":{"branches":66,"functions":81,"lines":94,"statements":94}},"testEnvironment":"node"},"lint-staged":{"*.js":["eslint --fix --config ./.eslintrc","git add"],"{package.json,README.md,LICENSE.md}":["projectz compile","git add"]},"config":{"commitizen":{"path":"cz-conventional-changelog"}},"badges":{"list":["travisci","npmversion","daviddm","daviddmdev"]},"maintainers":[{"name":"simenb","email":"sbekkhus91@gmail.com"},{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},{"name":"sveisvei","email":"sveinung.rosaker@gmail.com"},{"name":"trygve","email":"post@trygve-lie.com"}],"gitHead":"7ba7b26006cf06bf54a45f80ac8b8d549e3ff616","homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","_id":"@asset-pipe/sink-mem@1.1.2","_npmVersion":"5.5.1","_nodeVersion":"9.2.0","_npmUser":{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},"dist":{"integrity":"sha512-aJIW+OmX67aQlj9sQOqb6HIjniJX4qLrg43ySG4ZfODBMTuFE2glW4tjrLLOvyPlj86URozL5oWgMzYuEpHF1Q==","shasum":"724f08525efa1871d9281159ffb24a5e2d1fcc47","tarball":"https://registry.npmjs.org/@asset-pipe/sink-mem/-/sink-mem-1.1.2.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGNhSNLQR3xAJamEpe98EgIH05T2oH7cjzqA1ZFGUIrGAiEAtfNoZEOpsxg0mRW/2H8yIdSs3b2FB1Gp/K1tm6CXjiI="}]},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/sink-mem-1.1.2.tgz_1512404397646_0.6561782024800777"},"directories":{}},"1.1.3":{"name":"@asset-pipe/sink-mem","version":"1.1.3","author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"description":"Module for writing and reading asset feeds and js/css bundles to and from a simple in memory store","main":"./lib/sink.js","repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"keywords":["test"],"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"},{"name":"Simen Bekkhus","url":"https://github.com/SimenB"},{"name":"greenkeeper[bot]","url":"http://github.com/apps/greenkeeper"}],"engines":{"node":">=8"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","publishConfig":{"access":"public"},"dependencies":{"@asset-pipe/common":"^3.0.1","JSONStream":"^1.3.5","boom":"^7.3.0","concat-stream":"^1.6.2","readable-stream":"^3.1.0"},"devDependencies":{"commitizen":"^3.0.5","cz-conventional-changelog":"^2.1.0","eslint":"^5.10.0","eslint-config-finn":"^3.0.1","eslint-config-finn-prettier":"^3.0.2","eslint-plugin-import":"^2.14.0","husky":"^1.3.0","jest":"^23.6.0","lint-staged":"^8.1.0","prettier":"^1.15.3","projectz":"^1.7.3","semantic-release":"^15.13.1","travis-deploy-once":"^5.0.11"},"scripts":{"semantic-release":"semantic-release","travis-deploy-once":"travis-deploy-once","lint":"eslint .","test":"jest --coverage","lint:format":"eslint --fix .","precommit":"lint-staged","cm":"git-cz","readme":"projectz compile"},"jest":{"clearMocks":true,"coverageThreshold":{"global":{"branches":66,"functions":81,"lines":94,"statements":94}},"testEnvironment":"node"},"lint-staged":{"*.js":["eslint --fix --config ./.eslintrc","git add"],"{package.json,README.md,LICENSE.md}":["projectz compile","git add"]},"config":{"commitizen":{"path":"cz-conventional-changelog"}},"badges":{"list":["travisci","npmversion","daviddm","daviddmdev"]},"maintainers":[{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},{"name":"simenb","email":"sbekkhus91@gmail.com"},{"name":"sveisvei","email":"sveinung.rosaker@gmail.com"},{"name":"trygve","email":"post@trygve-lie.com"}],"gitHead":"20c27d28ecb2159313e60abde253d7e30683e043","homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","_id":"@asset-pipe/sink-mem@1.1.3","_npmVersion":"6.5.0","_nodeVersion":"9.11.2","_npmUser":{"name":"digitalsadhu","email":"digitalsadhu@gmail.com"},"dist":{"integrity":"sha512-6q3RqQPVnI9a3XF+/2vKlJK4DCY7a3tY+cxCVMAn1lytpkY4b3pFptdoiWeFEWH7CruBUQIeKordEgsaK2MjtQ==","shasum":"55d99b97344f6ceeebfa7242def9aebd6161d83b","tarball":"https://registry.npmjs.org/@asset-pipe/sink-mem/-/sink-mem-1.1.3.tgz","fileCount":4,"unpackedSize":12539,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcG3ORCRA9TVsSAnZWagAAHooP/j4t+HWmco2SyfJkb45Y\nerS1Lo5Nc9b8N3IjulruM6me7kuOzIoWS3xDFdI6vzgO4k0Q+4z6/4aA+Iww\n8j6keRQH3CbdmiR4lJC/e4OjP6in2/ow369BpbEmWBNuSs9/DkgTxtk//kZD\nh6blAxovCcG2H82ZWhQVKGOSQt4Ixc2Zk+3V7dOw1EXM3UK/H/0EH669hUl7\nHKMy2P4NWtoFfDht++hOaBkOWIAlpQyoucsbYzpJvfr/AgV9OIiqqLVGrnOi\n0eum/qf0ref2LOiI5JhmlPlPX+nuMp9Ohz/RqHSwXnp82ZHAFnXcGJZVu2pp\n1g2PEfgb9okgFn3XiAMhf+cxOgnHriy3RIyUHomzvgWZm4EV/rkTYC6whkrC\neJQD7Ddo4u4cB15pZnC0IPSCZt9HoAOidr0VS1wElkzwhTG2BgccWZxL56LW\nfN7DQWcnoKM4R5I7Mp18+3B/lP0eu04FHH/Hagao+AmrAk+valioNw8HmR0F\nzQEBSmXDC17CHWm6mn5Uhwd+ZDLTq2TApkvja/+w4y8R+qWgOx75s7Yc9jys\n6useSunEJ1H1HdwdOzvIQNejGWBL3ChPpXsJ+n3BB90PADt5EZ/49zVJHh6n\nW7cJNe7x5y386HtCD8W7AgJe6PDt/eRDrNKA+achI8fpcRK0VXogEl/s+HdK\nwjBJ\r\n=Nu1u\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHrJod7mP14eJtUm3dbFNsG6FrnpwBzF6tKlII4v1Mm1AiAdaDJtbthm3Y2py9+TNkjt7Z34ofvPZRo0CeOUxiIJxQ=="}]},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/sink-mem_1.1.3_1545302929418_0.41358873413032327"},"_hasShrinkwrap":false}},"readme":"<!-- TITLE/ -->\n\n<h1>@asset-pipe/sink-mem</h1>\n\n<!-- /TITLE -->\n\n\n<!-- BADGES/ -->\n\n<span class=\"badge-travisci\"><a href=\"http://travis-ci.org/asset-pipe/asset-pipe-sink-mem\" title=\"Check this project's build status on TravisCI\"><img src=\"https://img.shields.io/travis/asset-pipe/asset-pipe-sink-mem/master.svg\" alt=\"Travis CI Build Status\" /></a></span>\n<span class=\"badge-npmversion\"><a href=\"https://npmjs.org/package/@asset-pipe/sink-mem\" title=\"View this project on NPM\"><img src=\"https://img.shields.io/npm/v/@asset-pipe/sink-mem.svg\" alt=\"NPM version\" /></a></span>\n<span class=\"badge-daviddm\"><a href=\"https://david-dm.org/asset-pipe/asset-pipe-sink-mem\" title=\"View the status of this project's dependencies on DavidDM\"><img src=\"https://img.shields.io/david/asset-pipe/asset-pipe-sink-mem.svg\" alt=\"Dependency Status\" /></a></span>\n<span class=\"badge-daviddmdev\"><a href=\"https://david-dm.org/asset-pipe/asset-pipe-sink-mem#info=devDependencies\" title=\"View the status of this project's development dependencies on DavidDM\"><img src=\"https://img.shields.io/david/dev/asset-pipe/asset-pipe-sink-mem.svg\" alt=\"Dev Dependency Status\" /></a></span>\n\n<!-- /BADGES -->\n\n\n[![Greenkeeper badge](https://badges.greenkeeper.io/asset-pipe/asset-pipe-sink-mem.svg)](https://greenkeeper.io/)\n\nA [asset-pipe][asset-pipe] sink for writing and reading asset feeds and js/css bundles to and from a\nsimple in memory store.\n\nThe intention of the [asset-pipe][asset-pipe] sink modules is to use be able to write and read files\nto different backends by just swapping modules. By each sink implementing the same public API it is\npossible to ex use this module in one environment and another sink module in another environment.\n\nThese sinks are normally used by the [asset-pipe-build-server][asset-pipe-build-server].\n\n\n\n## Installation\n\n```bash\n$ npm install @asset-pipe/sink-mem\n```\n\n\n\n## Example\n\nRead an asset feed from the store and serve it on http:\n\n```js\nconst express = require('express');\nconst Sink = require('@asset-pipe/sink-mem');\n\nconst app = express();\nconst sink = new Sink();\n\napp.get('/', (req, res, next) => {\n    const file = sink.reader('feed.json');\n    file.on('file not found', () => {\n        res.status(404).send('File not found');\n    });\n    file.on('file found', () => {\n        res.status(200);\n        file.pipe(res);\n    });\n});\n\napp.listen(8000);\n```\n\n\n\n## API\n\nThis module have the following API:\n\n### constructor()\n\nConstructor takes no arguments.\n\n\n### get(fileName: string): Promise<string>\n\nAsync method for reading a file from storage\n\n### set(fileName: string, fileContent: string): Promise<void>\n\nAsync method for writing file to storage\n\n### has(fileName: string): Promise<Boolean>\n\nAsync method for checking if file exist in storage\n\n### dir(directoryName: string): Promise<Array>\n\nAsync method for getting all files in a given directory\n\n### writer(type)\n\nMethod for writing a file to memory. Returns a write stream.\n\nSupported arguments are:\n\n - `type` - String - File type of the file to write. Used as extension of the persisted file. - Required\n\nEvents:\n\n - `file saved` - When a file have been sucessfully persisted. Emits with: `id` and `file`.\n - `file not saved` -  When a file could not be persisted. Emits with: `error`.\n - `error` -  When an error occured during persistence. Emits with: `error`.\n\n\n### reader(file)\n\nMethod for reading a file from memory. Returns a read stream.\n\nSupported arguments are:\n\n - `file` - String - File name of the file to read. - Required\n\nEvents:\n\n - `file found` - When the file we want to read is found. Emits with: `file`.\n - `file not saved` -  When the file we want to read is not found. Emits with: `file`.\n\n\n\n## License\n\nThe MIT License (MIT)\n\nCopyright (c) 2017 - Trygve Lie - post@trygve-lie.com\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n\n\n\n[asset-pipe]: https://github.com/asset-pipe\n[asset-pipe-build-server]: https://github.com/asset-pipe/asset-pipe-build-server\n\n## Contributing\n\nThe contribution process is as follows:\n\n- Fork this repository.\n- Make your changes as desired.\n- Run the tests using `npm test`. This will also check to ensure that 100% code coverage is maintained. If not you may need to add additional tests.\n- Stage your changes.\n- Run `git commit` or, if you are not familiar with [semantic commit messages](https://docs.google.com/document/d/1QrDFcIiPjSLDn3EL15IJygNPiHORgU1_OOAqWjiDU5Y/edit), please run `npm run cm` and follow the prompts instead which will help you write a correct semantic commit message.\n- Push your changes and submit a PR.\n","maintainers":[{"email":"post@trygve-lie.com","name":"trygve"},{"email":"digitalsadhu@gmail.com","name":"digitalsadhu"}],"time":{"modified":"2022-04-04T15:51:20.960Z","created":"2017-11-10T14:15:49.001Z","1.0.0":"2017-11-10T14:15:49.001Z","1.1.0":"2017-11-17T06:56:17.577Z","1.1.1":"2017-11-17T08:00:40.376Z","1.1.2":"2017-12-04T16:19:58.622Z","1.1.3":"2018-12-20T10:48:49.510Z"},"homepage":"https://github.com/asset-pipe/asset-pipe-sink-mem#readme","keywords":["test"],"repository":{"type":"git","url":"git+https://github.com/asset-pipe/asset-pipe-sink-mem.git"},"contributors":[{"name":"Trygve Lie","email":"post@trygve-lie.com"},{"name":"Trygve Lie","url":"http://www.trygve-lie.com/"},{"name":"Greenkeeper","url":"http://greenkeeper.io/"},{"name":"Richard Walker","url":"https://github.com/digitalsadhu"},{"name":"Sveinung Røsaker","url":"https://github.com/sveisvei"},{"name":"Simen Bekkhus","url":"https://github.com/SimenB"},{"name":"greenkeeper[bot]","url":"http://github.com/apps/greenkeeper"}],"author":{"name":"Trygve Lie","email":"post@trygve-lie.com"},"bugs":{"url":"https://github.com/asset-pipe/asset-pipe-sink-mem/issues"},"license":"MIT","readmeFilename":"README.md"}