{"name":"@sveltejs/svelte-virtual-list","version":"3.0.0","description":"A <VirtualList> component for Svelte apps","main":"VirtualList.svelte","svelte":"VirtualList.svelte","scripts":{"build":"rollup -c","dev":"rollup -cw","prepublishOnly":"npm test","test":"node test/runner.js","test:browser":"npm run build && serve test/public","pretest":"npm run build","lint":"eslint src/VirtualList.svelte"},"devDependencies":{"eslint":"^5.12.1","eslint-plugin-svelte3":"git+https://github.com/sveltejs/eslint-plugin-svelte3.git","port-authority":"^1.0.5","puppeteer":"^1.9.0","rollup":"^1.1.2","rollup-plugin-commonjs":"^9.2.0","rollup-plugin-node-resolve":"^4.0.0","rollup-plugin-svelte":"^5.0.1","sirv":"^0.2.2","svelte":"^3.0.0-beta.2","tap-diff":"^0.1.1","tap-dot":"^2.0.0","tape-modern":"^1.1.1"},"repository":{"type":"git","url":"git+https://github.com/sveltejs/svelte-virtual-list.git"},"author":{"name":"Rich Harris"},"license":"LIL","keywords":["svelte"],"gitHead":"0746e27487f80298048f93e7b83c8b724d24de65","bugs":{"url":"https://github.com/sveltejs/svelte-virtual-list/issues"},"homepage":"https://github.com/sveltejs/svelte-virtual-list#readme","_id":"@sveltejs/svelte-virtual-list@3.0.0","_nodeVersion":"12.2.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-9gDqmcmsKS1Jjt1pk3D5cLSCYfdF/x6VxjnAeyM5UG4mfF3VGsP+WcuGDE/10q4edne/OkBKwicOgiq5AaK8EQ==","shasum":"36730819db704141185998d7302d0ab232c9226d","tarball":"http://registry-npm.ywwl.com/@sveltejs/svelte-virtual-list/download/@sveltejs/svelte-virtual-list-3.0.0.tgz","fileCount":5,"unpackedSize":9077,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdDU7OCRA9TVsSAnZWagAAQTMP/iafW09PmP+QraZBb70J\nl+9hWYFB/D7XDUDNibZz2Kw09QErL+hGrPa3LwJefUoM/AXC0fYQ1uztj/NL\nb/CAAah7jD31isai62oo5EH6y/yccZAfgQ8rCv8xQtSo1dpObLEcamDQV/HX\nMuydrOoGtQWTYIeXENeK8hCD4z8fr+vwUTFKH4a56LMKb3UdpfWT55l/02ve\nO+DSlcDHV0mpJJHoaXJnuYi4Yus89h1kM3dkYaxnUAef0RyTjl79mTd9jz1p\nl4Uq5Gv+PNWyEfPGty+mNiG7mRrvHhR0dBY2CIDBRMCv+1rZYHwsFeUp8FAp\nDJWPBxUI0zUZ3glHHgbngvKVgx/NvleRZT4Pp3CuYMVatwDtTHaHzso0EfcE\ngTEYjqoqcp+SXWqaUZ+zzAAeXoPyKWHheMzSAf0nQ6vrw+l00hxUXcIMKAjh\nr+LYgdy/pq3Fc8GrUMa/bUsaW9EwSV2PnNfCgnewzfX4QNh9PhkgWWW7ygK2\nPOn+T9v5UKiGkFpcPq1P38TkDhycVqKAaW+/8grQwtn7936gC32E7sesCqPW\nY6Adtfn3LPCvipyZtmXhQLjmq4VnSVkZ+bhnQNE0gVTE2kklvFXeadzH+wJp\nw2CHaMZ1UWm6mkhRohcN4yQ+3S+2sddk/hKaj3DrzxpvBcQD62NYz9lMTvsB\n/3gV\r\n=3jTT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICJfsmWS7kyYhUhjE0sPWi8pduhXKXF9cLB6Do2/E4AaAiEA5ps8pK0CusSS6JCLbux3KFrzKAs9QfWI3H69DUO9Pc8="}],"size":3734,"noattachment":false,"key":"/@sveltejs/svelte-virtual-list/-/@sveltejs/svelte-virtual-list-3.0.0.tgz"},"maintainers":[{"email":"npm@chor.date","name":"conduitry"},{"email":"richard.a.harris@gmail.com","name":"rich_harris"},{"email":"richard.a.harris+svelte@gmail.com","name":"svelte-admin"}],"_npmUser":{"name":"rich_harris","email":"richard.a.harris@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/svelte-virtual-list_3.0.0_1561153230141_0.5072403884017747"},"_hasShrinkwrap":false,"readme":"# svelte-virtual-list ([demo](https://svelte.dev/repl/f78ddd84a1a540a9a40512df39ef751b))\n\nA virtual list component for Svelte apps. Instead of rendering all your data, `<VirtualList>` just renders the bits that are visible, keeping your page nice and light.\n\n## Installation\n\n```bash\nyarn add @sveltejs/svelte-virtual-list\n```\n\n\n## Usage\n\n```html\n<script>\n  import VirtualList from '@sveltejs/svelte-virtual-list';\n\n  const things = [\n    // these can be any values you like\n    { name: 'one', number: 1 },\n    { name: 'two', number: 2 },\n    { name: 'three', number: 3 },\n    // ...\n    { name: 'six thousand and ninety-two', number: 6092 }\n  ];\n</script>\n\n<VirtualList items={things} let:item>\n  <!-- this will be rendered for each currently visible item -->\n  <p>{item.number}: {item.name}</p>\n</VirtualList>\n```\n\n\n## `start` and `end`\n\nYou can track which rows are visible at any given by binding to the `start` and `end` values:\n\n```html\n<VirtualList items={things} bind:start bind:end>\n  <p>{item.number}: {item.name}</p>\n</VirtualList>\n\n<p>showing {start}-{end} of {things.length} rows</p>\n```\n\nYou can rename them with e.g. `bind:start={a} bind:end={b}`.\n\n\n## `height`\n\nBy default, the `<VirtualList>` component will fill the vertical space of its container. You can specify a different height by passing any CSS length:\n\n```html\n<VirtualList height=\"500px\" items={things} let:item>\n  <p>{item.number}: {item.name}</p>\n</VirtualList>\n```\n\n\n## `itemHeight`\n\nYou can optimize initial display and scrolling when the height of items is known in advance. This should be a number representing a pixel value.\n\n```html\n<VirtualList itemHeight={48} items={things} let:item>\n  <p>{item.number}: {item.name}</p>\n</VirtualList>\n```\n\n\n## Configuring webpack\n\nIf you're using webpack with [svelte-loader](https://github.com/sveltejs/svelte-loader), make sure that you add `\"svelte\"` to [`resolve.mainFields`](https://webpack.js.org/configuration/resolve/#resolve-mainfields) in your webpack config. This ensures that webpack imports the uncompiled component (`src/index.html`) rather than the compiled version (`index.mjs`) — this is more efficient.\n\nIf you're using Rollup with [rollup-plugin-svelte](https://github.com/rollup/rollup-plugin-svelte), this will happen automatically.\n\n\n## License\n\n[LIL](LICENSE)\n","publish_time":1561153230252,"_cnpm_publish_time":1561153230252,"dist-tags":{"latest":"3.0.1","next":"3.0.0-alpha.1"}}