{"_id":"y-array2","_rev":"4-d7ce5ce8948cc516be68189068b525cf","name":"y-array2","dist-tags":{"latest":"1.5.0"},"versions":{"11.0.0-5":{"name":"y-array2","version":"11.0.0-5","description":"Array Type for Yjs","main":"./y-array.node.js","browser":"./y-array.js","module":"./src/y-array.js","scripts":{"test":"npm run lint","dist":"rollup -c rollup.browser.js && rollup -c rollup.node.js","lint":"standard","watch":"concurrently 'rollup -wc rollup.browser.js' 'rollup -wc rollup.node.js'","postversion":"npm run dist","postpublish":"tag-dist-files --overwrite-existing-tag"},"files":["y-array.*"],"standard":{"ignore":["/y-array.js","/y-array.test.js"]},"repository":{"type":"git","url":"git+https://github.com/y-js/y-array.git"},"keywords":["Yjs","OT","Collaboration","Synchronization","ShareJS","Coweb","Concurrency"],"author":{"name":"Kevin Jahns","email":"kevin.jahns@rwth-aachen.de"},"license":"MIT","bugs":{"url":"https://github.com/y-js/yjs/issues"},"homepage":"http://y-js.org","devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-preset-latest":"^6.24.1","chance":"^1.0.10","concurrently":"^3.4.0","cutest":"^0.1.9","rollup-plugin-babel":"^2.7.1","rollup-plugin-commonjs":"^8.0.2","rollup-plugin-multi-entry":"^2.0.1","rollup-plugin-node-resolve":"^3.0.0","rollup-plugin-uglify":"^1.0.2","rollup-watch":"^3.2.2","standard":"^10.0.2","tag-dist-files":"^0.1.6"},"peerDependencies":{"yjs":">=13.0.0-0 <14.0.0"},"gitHead":"c4efe55209e1b9fffc00d793687ab023abb8e82d","_id":"y-array2@11.0.0-5","_npmVersion":"5.6.0","_nodeVersion":"8.11.1","_npmUser":{"name":"stiin","email":"dinesh@micropyramid.com"},"dist":{"integrity":"sha512-qFGH9Fqi0CLC7CmK019lshd7FHVBLCb8SdiaMcnqdwE36QAgmW1OktRo0iS2jccRecGek2ve2ixZzLRusJ1T2g==","shasum":"59847fad112e4ed3374622982f71f11f13c28321","tarball":"https://registry.npmjs.org/y-array2/-/y-array2-11.0.0-5.tgz","fileCount":3,"unpackedSize":5880,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH29kCRA9TVsSAnZWagAA7zEP/iGgKwqlbtp0Nrkao3a6\n4VF6lQN7uHmgoA4Gr2ZytLQOUQxseYUIBQxY962ggggSyjy4XLesAD+N8hLt\nonje3bRcEkfKvWovyyT/Q6cwOmCJSppQNqA0mzQZpxCD74bvgwuDz8HauS+t\nKcbzBrNoKo8hBy5oBxum+3uy3ReEbkojP/fXykEHaBd16RmchTYo1fd+2Hkb\nprSZUM6kNFV7+ishQQLXBbiDmDj6sdYmaety6jPqMOzfOWBsjiPJFcRy7szb\nmLWarMKqc5+Z0gdfDru4CldEzjrq1cM8jTTm3rtg25021L2UtOwcd/xjaomH\nz9spZRCeGvqZpJUbEhAcYUj8pi5qQDaMg8u0AX7FGvQUxXw/cGfNFDcdeBrd\nKhL+/psK8BPnAIrMeyMh+x6056hGKzuaLKdXzH01kcLnlS1MPBRdfgs00OBQ\nUmyCOPkYylKILPmy+xpRaLVy+hERA5Mb2PIDoTNkI2t50GTW4c90hBG2di5m\nf9mm+YR9dhfcZ7CKxfwyRE8o3d+F3LkT614p+XIRK2WEABSC5AepyF+NTIPi\nOcxuhAvSoY9Rl0BU+qZbNKnKX96DgrjslMMuaYynSU77lrA31NHe5hD7e4GW\necnQfgxXzDC7efKJ2t0SbSVnwSTdxqRIqHYB3qmlY6jwOz0IClvMy+R9ZqGv\n29lx\r\n=oFLt\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFiqpkYVb+71uk6fy4IzOUMhVfcA9c0TVLKFprQYY5G2AiB74AeC1fd3IBrRHaXyI7DpWpFoifFJY0PdlU//aWxFAQ=="}]},"maintainers":[{"name":"stiin","email":"dinesh@micropyramid.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/y-array2_11.0.0-5_1528786787685_0.46259241531896955"},"_hasShrinkwrap":false},"1.0.0":{"name":"y-array2","version":"1.0.0","description":"Array Type for Yjs","main":"./y-array.node.js","browser":"./y-array.js","module":"./src/y-array.js","scripts":{"test":"npm run lint","dist":"rollup -c rollup.browser.js && rollup -c rollup.node.js","lint":"standard","watch":"concurrently 'rollup -wc rollup.browser.js' 'rollup -wc rollup.node.js'","postversion":"npm run dist","postpublish":"tag-dist-files --overwrite-existing-tag"},"files":["y-array.*"],"standard":{"ignore":["/y-array.js","/y-array.test.js"]},"repository":{"type":"git","url":"git+https://github.com/y-js/y-array.git"},"keywords":["Yjs","OT","Collaboration","Synchronization","ShareJS","Coweb","Concurrency"],"author":{"name":"Kevin Jahns","email":"kevin.jahns@rwth-aachen.de"},"license":"MIT","bugs":{"url":"https://github.com/y-js/yjs/issues"},"homepage":"http://y-js.org","devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-preset-latest":"^6.24.1","chance":"^1.0.10","concurrently":"^3.4.0","cutest":"^0.1.9","rollup-plugin-babel":"^2.7.1","rollup-plugin-commonjs":"^8.0.2","rollup-plugin-multi-entry":"^2.0.1","rollup-plugin-node-resolve":"^3.0.0","rollup-plugin-uglify":"^1.0.2","rollup-watch":"^3.2.2","standard":"^10.0.2","tag-dist-files":"^0.1.6"},"peerDependencies":{"yjs":">=13.0.0-0 <14.0.0"},"dependencies":{"rollup":"^0.60.2"},"gitHead":"c4efe55209e1b9fffc00d793687ab023abb8e82d","_id":"y-array2@1.0.0","_npmVersion":"5.6.0","_nodeVersion":"8.11.1","_npmUser":{"name":"stiin","email":"dinesh@micropyramid.com"},"dist":{"integrity":"sha512-whOg0fFbdHazWETKGXJbt4U+Guoxzh8Eb01DlpmleNNdpSCMjPAa94R2kG5vWIiTVX+XOAeklxYcUGVf170/ig==","shasum":"11e82838b4b153dc7f20bede561ca2d5d44171f2","tarball":"https://registry.npmjs.org/y-array2/-/y-array2-1.0.0.tgz","fileCount":7,"unpackedSize":68204,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH3mkCRA9TVsSAnZWagAAedkP/jU0HCeE3T2YBmzKq/pE\npP7/cVEKtarW3YpHBHaIhGew0AkZP+6DuUFtW4U8VMCb9P+UF6bdFwPtaxhg\n7VuOoiOPk6oK3Bbb/lfyJUQAKd5rTEd0eYAO0aK/2abpD6/8JuYymvppTwhu\n+f7J1bXaN+N10MhVTXwREjvUix75+P8PDqPv0TAK5Un3hHaFsOyDnnt3hIwZ\nnAReMNN6tFVr5WdbortZYL0HTOTDFkcNzV/dQWaUIUlGnio0uHsqgrD2NJSB\nLeI6AV1PIAeEG3yP5j+WLVSoa6Zb43yR+zBXsxW4Upif+qD26T0s0MdUoWcO\ncZuX0UdhE8U7+MCIQrAOVCxzELT50XnpF3i9S8WAKJpelg1bDcUhtVvK5yOf\n7oz8/BnqTfm9zL629vEMFLgrcRsRlc2r5Ok8zzdyD291Mew6YI+2BMnqQ8Q1\n74j8Wt80NA4Cpi5ZPerSIK+QTSnFKyXk1IDYbmDDj8ZOjdd5gGexcJoD4uSu\nr5BDUo7IeZkJDi5B3LF1tq3bj1J2zD7hXXilC/6D6IeYoQkJkR8NbE0nYBie\ne3CWgr4iqu2mjLRFpZ43A4Avc2UUKJgIof3eDFBUIrSeFfCKTKu7JgnS8ML3\n+BiFgvH9jxEnLGFS3GOjnEuvOopZx+FZYlbgQl+eWoJRxkKiCnQQDT60l1J2\n6XJr\r\n=n/XT\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDdQ2kDiqcBJwA4pXkOam1jsfQGJp9k1ObmP+Ei0CzPmwIgWWuD2IX4Ju22jW/huRJwNdt0FoFgrRlZTEG+LB/ubOY="}]},"maintainers":[{"name":"stiin","email":"dinesh@micropyramid.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/y-array2_1.0.0_1528789411626_0.7610726890093007"},"_hasShrinkwrap":false},"1.2.0":{"name":"y-array2","version":"1.2.0","description":"Array Type for Yjs","main":"./y-array.node.js","browser":"./y-array.js","module":"./src/y-array.js","scripts":{"test":"npm run lint","dist":"rollup -c rollup.browser.js && rollup -c rollup.node.js","lint":"standard","watch":"concurrently 'rollup -wc rollup.browser.js' 'rollup -wc rollup.node.js'","postversion":"npm run dist","postpublish":"tag-dist-files --overwrite-existing-tag"},"standard":{"ignore":["/y-array.js","/y-array.test.js"]},"repository":{"type":"git","url":"git+https://github.com/y-js/y-array.git"},"keywords":["Yjs","OT","Collaboration","Synchronization","ShareJS","Coweb","Concurrency"],"author":{"name":"Kevin Jahns","email":"kevin.jahns@rwth-aachen.de"},"license":"MIT","bugs":{"url":"https://github.com/y-js/yjs/issues"},"homepage":"http://y-js.org","devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-preset-latest":"^6.24.1","chance":"^1.0.10","concurrently":"^3.4.0","cutest":"^0.1.9","rollup-plugin-babel":"^2.7.1","rollup-plugin-commonjs":"^8.0.2","rollup-plugin-multi-entry":"^2.0.1","rollup-plugin-node-resolve":"^3.0.0","rollup-plugin-uglify":"^1.0.2","rollup-watch":"^3.2.2","standard":"^10.0.2","tag-dist-files":"^0.1.6"},"peerDependencies":{"yjs":">=13.0.0-0 <14.0.0"},"dependencies":{"rollup":"^0.60.2"},"gitHead":"c4efe55209e1b9fffc00d793687ab023abb8e82d","_id":"y-array2@1.2.0","_npmVersion":"5.6.0","_nodeVersion":"8.11.1","_npmUser":{"name":"stiin","email":"dinesh@micropyramid.com"},"dist":{"integrity":"sha512-+YcfB77Kq9qk4stVgPpVkf7cDSor+ORJwZsshT4Pz+8bHtTO8hKGKdvnUcUvy9OKrZ0WQBPbTXj0/uoYEXwuWw==","shasum":"99c1bbb4fcb723560a8e27f0bd6cb7d1cd0623fa","tarball":"https://registry.npmjs.org/y-array2/-/y-array2-1.2.0.tgz","fileCount":8,"unpackedSize":19158,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH36oCRA9TVsSAnZWagAAnzwP/RbQQ18c9KS4ssBPdcKB\nmXqNsoPjrCcGRMvoxEUnNutf5HWxdhNVunppMKWzaeLtUt9h7hchRNI4m8OB\nM9n4unmQTUiDVVecFX1qmUyBLkIv6NBdiDObVxi1+vMzNHkb24WArmbYBpkR\nX+NP7K71SPi20XDytDXqI8BirOZ8dpqVpO1ifP0Y8Co8/QbUkY0unXpyxDgE\nUTrc1D5n4xY98q6EyV7/GBn5L1jdhBvWqjY9fSMfGwe0F9PhNKztD0aU9jqn\nhGATAni9dVxQjc073gIle0bA+wwioo1FkVZmjs4KNNq7+BQYxyFMOUjbkeJh\nndAtIs7i69lNs/2OIH4R+6E91SHzAC9tcBsZNuujTokc0PV8CiCTmFmkXBpY\nXmOOVy8feKY9LE97e7GE+05m77JYQvkf2V3RNNGyagmcuBP3/KaS9L8zu/DX\nLJAT7UeJ01bfnSDnFXvJ1N1sCDBE6MPKrxvV4zFF1D1fdPK5Uphsq6lsWjkX\n5nlwDZ2Nnz8XA5FqLYqT3ZikXK+hUWPzVnLK329+523RlmC5pdMEu7aK0oJ6\nF0+qhaCsi9AHolm57A1Ey4gboOaeVlpU+DXoMpQ+PdC1pVCRswJTkGSzI3UN\n+8W/gt/7wKOwmPtH/666ew9wydfojOTsqRHVSTMWdGHcZi6YNRAhRoA53Vwn\nDiwE\r\n=Sy+H\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHRHxNOUKHEl6B1PzYdJYDXZ50vcP8Xa8hO17zQIcj1XAiEAyVpinI4nAniURtUDPZzhdD9RUZP9LkREWG6YVHBRxvc="}]},"maintainers":[{"name":"stiin","email":"dinesh@micropyramid.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/y-array2_1.2.0_1528790696491_0.36277055839071126"},"_hasShrinkwrap":false},"1.5.0":{"name":"y-array2","version":"1.5.0","description":"Array Type for Yjs","main":"./y-array.node.js","browser":"./y-array.js","module":"./src/y-array.js","scripts":{"test":"npm run lint","dist":"rollup -c rollup.browser.js && rollup -c rollup.node.js","lint":"standard","watch":"concurrently 'rollup -wc rollup.browser.js' 'rollup -wc rollup.node.js'","postversion":"npm run dist","postpublish":"tag-dist-files --overwrite-existing-tag"},"files":["y-array.*"],"standard":{"ignore":["/y-array.js","/y-array.test.js"]},"repository":{"type":"git","url":"git+https://github.com/y-js/y-array.git"},"keywords":["Yjs","OT","Collaboration","Synchronization","ShareJS","Coweb","Concurrency"],"author":{"name":"Kevin Jahns","email":"kevin.jahns@rwth-aachen.de"},"license":"MIT","bugs":{"url":"https://github.com/y-js/yjs/issues"},"homepage":"http://y-js.org","devDependencies":{"babel-plugin-external-helpers":"^6.22.0","babel-preset-latest":"^6.24.1","chance":"^1.0.10","concurrently":"^3.4.0","cutest":"^0.1.9","rollup-plugin-babel":"^2.7.1","rollup-plugin-commonjs":"^8.0.2","rollup-plugin-multi-entry":"^2.0.1","rollup-plugin-node-resolve":"^3.0.0","rollup-plugin-uglify":"^1.0.2","rollup-watch":"^3.2.2","standard":"^10.0.2","tag-dist-files":"^0.1.6"},"peerDependencies":{"yjs":">=13.0.0-0 <14.0.0"},"gitHead":"c4efe55209e1b9fffc00d793687ab023abb8e82d","_id":"y-array2@1.5.0","_npmVersion":"5.6.0","_nodeVersion":"8.11.1","_npmUser":{"name":"stiin","email":"dinesh@micropyramid.com"},"dist":{"integrity":"sha512-H9S8rn3CDyuJjDKSUqoMsvrKf1WzaCt4/UnxRhM9SCrS7f8EaoywcJCqxr6dOBlWljOKzKoj5Acv/aV+v20Pqw==","shasum":"fed9968c91f0990fbf85a61390474376398bd9ee","tarball":"https://registry.npmjs.org/y-array2/-/y-array2-1.5.0.tgz","fileCount":7,"unpackedSize":68155,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH5CJCRA9TVsSAnZWagAA3NUQAJdaKwzlus32ZAlv1w0N\nED7J8bV4MeQF2yrdR4DNh9EwerUvhL12HlfRtVg8lY3jwOl7Wsp9QNa/t1hX\nPRna7yu+v8HeHaq+8N3w6RbeBmfJ98axCmpSEz1vtFLcBgJqsbhlECpkHsEr\nuX5850tAqXIQ8D5Mz16isCMmm0VJS4StmDFHktTVb99uY1kDNeR+/EpLN5JU\nQGKOTx6Ylv7eXj0jFqURoqVXIDwZnMDyrrS+zNMlH0L595a0ooaI3tj+0Rbw\nqHfz7YMxuvR/a/hPaOqytZshA1ViUCSKnl+uATWjpjjcXmlvw86B40VNug7y\nR13APmwgjmNz/UsOSYtqNvfHMJ669lxbrEiSIXlpXg8NUPqtG8GG0HpvxX/U\n+o1BhgiO0Ya7dUCgl2D55xToAG2EEvTGiD1f5Cat30nXZmWP1RuMw1qA3inL\nEpSv2KH69cZp6uuc90JvrNwX9aCvDJKMSwa7ZprdSKR5gh+tfI5o3buRn1NI\ncjoOblOsK8+4Tux820+gJbRRZfTFTLgpBrA7jdVn/PP3PSLWetkwOJ97UdJD\nJ874hIctygXyGTVNwFOuH6H7L4AZS2dBFSIr5Jf0S/Ywbn07RUPkYv89DszL\n3SMRox5AjJBNWhE0Na5uASEFzUPPpkes609YWrTnSEE8Xxb6uF6mvdruluxj\nuqS4\r\n=PjbH\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD+jTk7sgHUC78RrAJYxCrVoofLMB6mfeAw3tp5es4jDgIgYPN/AZ27o2kUAds3PA1xf02iOpLFbbV/5Szzo1OveIs="}]},"maintainers":[{"name":"stiin","email":"dinesh@micropyramid.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/y-array2_1.5.0_1528795273216_0.1171310551740552"},"_hasShrinkwrap":false}},"time":{"created":"2018-06-12T06:59:47.684Z","11.0.0-5":"2018-06-12T06:59:47.738Z","modified":"2022-05-25T02:47:10.060Z","1.0.0":"2018-06-12T07:43:31.738Z","1.2.0":"2018-06-12T08:04:56.570Z","1.5.0":"2018-06-12T09:21:13.296Z"},"maintainers":[{"name":"stiin","email":"dinesh@micropyramid.com"}],"description":"Array Type for Yjs","homepage":"http://y-js.org","keywords":["Yjs","OT","Collaboration","Synchronization","ShareJS","Coweb","Concurrency"],"repository":{"type":"git","url":"git+https://github.com/y-js/y-array.git"},"author":{"name":"Kevin Jahns","email":"kevin.jahns@rwth-aachen.de"},"bugs":{"url":"https://github.com/y-js/yjs/issues"},"license":"MIT","readme":"# Array Type for [Yjs](https://github.com/y-js/yjs)\n\nThis plugins provides a shareable Array type. You can insert and delete objects in y-array. The objects must either be a custom type,\nor fulfill the following property: `v equals JSON.parse(JSON.stringify(v))` (according to your definition of equality)\n\n## Use it!\nInstall this with bower or npm.\n\n##### Bower\n```\nbower install y-array --save\n```\n\n##### NPM\n```\nnpm install y-array --save\n```\n\n### Array Object\n\n##### Reference\n\n* .insert(position, contents)\n  * Insert an array of content at a position\n  * You can also insert types `array.insert(0, Y.Map)`\n  * If not a shared type, the content should fulfill the following property: `content equals JSON.parse(JSON.stringify(content))` (according to your notion of equality)\n* .push(content)\n  * Insert content at the end of the Array\n  * Also see `.insert(..)`\n* .delete(position, length)\n  * Delete content. The *length* parameter is optional and defaults to 1\n* .toArray()\n  * Retrieve the complete content as an array\n* .get(position)\n  * Retrieve content from a position\n* .observe(function observer(event){..})\n  * The `observer` is called whenever something on this array changes\n  * Throws insert, and delete events (`event.type`)\n  * Insert event example: `{type: 'insert', index: 0, values: [0, 1, 2], length: 3}`\n  * Delete event example: `{type: 'delete', index: 0, oldValues: [0, 1, 2], length: 3}`\n* .observeDeep(function observer(event){..})\n  * Same as .observe, but catches events from all children (if they support .observeDeep)\n  * `event.path` specifies the path of the change event\n* .unobserve(f)\n  * Delete an observer\n\n\n# A note on intention preservation\nIf two users insert something at the same position concurrently, the content that was inserted by the user with the higher user-id will be to the right of the other content. In the OT world we often speak of *intention preservation*, which is very loosely defined in most cases. This type has the following notion of intention preservation: When a user inserts content *c* after a set of content *C_left*, and before a set of content *C_right*, then *C_left* will be always to the left of c, and *C_right* will be always to the right of *c*. Since content is only marked as deleted (until all conflicts are resolved), this notion of intention preservation is very strong.\n\n# A note on time complexities\n* .insert(position, content)\n  * O(contents.length)\n* .push(content)\n  * O(1)\n* .delete(position, length)\n  * O(position + length)\n* .get(i)\n  * O(length)\n* Apply a delete operation from another user\n  * O(contents.length)\n* Apply an insert operation from another user\n  * Yjs does not transform against operations that do not conflict with each other.\n  * An operation conflicts with another operation if it intends to be inserted at the same position.\n  * Overall worst case complexety: O(|conflicts|^2)\n\n## Changelog\n\n### 10.0.0\n* Inserting & retrieving types are synchronous operations\n  * I.e. `y.share.array.get(0) // => returns a type instead of a promise (if there is a type at position 0)\n* Relies on Yjs@^12.0.0\n\n## License\nYjs is licensed under the [MIT License](./LICENSE).\n\n<kevin.jahns@rwth-aachen.de>\n","readmeFilename":"README.md"}