{"action":"created","issue":{"url":"https://api.github.com/repos/olivernn/lunr.js/issues/284","repository_url":"https://api.github.com/repos/olivernn/lunr.js","labels_url":"https://api.github.com/repos/olivernn/lunr.js/issues/284/labels{/name}","comments_url":"https://api.github.com/repos/olivernn/lunr.js/issues/284/comments","events_url":"https://api.github.com/repos/olivernn/lunr.js/issues/284/events","html_url":"https://github.com/olivernn/lunr.js/issues/284","id":242038819,"number":284,"title":"Adding/Updating/Removing documents from a built Index","user":{"login":"ncphillips","id":824015,"avatar_url":"https://avatars2.githubusercontent.com/u/824015?v=4","gravatar_id":"","url":"https://api.github.com/users/ncphillips","html_url":"https://github.com/ncphillips","followers_url":"https://api.github.com/users/ncphillips/followers","following_url":"https://api.github.com/users/ncphillips/following{/other_user}","gists_url":"https://api.github.com/users/ncphillips/gists{/gist_id}","starred_url":"https://api.github.com/users/ncphillips/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ncphillips/subscriptions","organizations_url":"https://api.github.com/users/ncphillips/orgs","repos_url":"https://api.github.com/users/ncphillips/repos","events_url":"https://api.github.com/users/ncphillips/events{/privacy}","received_events_url":"https://api.github.com/users/ncphillips/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2017-07-11T13:00:54Z","updated_at":"2017-09-04T21:06:30Z","closed_at":null,"author_association":"NONE","body":"I'm a little annoyed at the assumption that lunr is only being used for static content, as we have quite the opposite situation. We're using lunr to provide search on a list that might grow, shrink, or have it's items modified at any time. \r\n\r\nI was looking forward to updating to version 2 but this change completely breaks our use case. My current workaround is to completely rebuild the entire index on every change. This is would be incredibly inefficient. \r\n\r\nI understand the benefits of immutability, but my feeling is that it could have been implemented internally without breaking the API.\r\n\r\nIs there any way they could be added back to v2?"},"comment":{"url":"https://api.github.com/repos/olivernn/lunr.js/issues/comments/327028111","html_url":"https://github.com/olivernn/lunr.js/issues/284#issuecomment-327028111","issue_url":"https://api.github.com/repos/olivernn/lunr.js/issues/284","id":327028111,"user":{"login":"abastardi","id":1295688,"avatar_url":"https://avatars3.githubusercontent.com/u/1295688?v=4","gravatar_id":"","url":"https://api.github.com/users/abastardi","html_url":"https://github.com/abastardi","followers_url":"https://api.github.com/users/abastardi/followers","following_url":"https://api.github.com/users/abastardi/following{/other_user}","gists_url":"https://api.github.com/users/abastardi/gists{/gist_id}","starred_url":"https://api.github.com/users/abastardi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abastardi/subscriptions","organizations_url":"https://api.github.com/users/abastardi/orgs","repos_url":"https://api.github.com/users/abastardi/repos","events_url":"https://api.github.com/users/abastardi/events{/privacy}","received_events_url":"https://api.github.com/users/abastardi/received_events","type":"User","site_admin":false},"created_at":"2017-09-04T21:06:30Z","updated_at":"2017-09-04T21:06:30Z","author_association":"NONE","body":"@olivernn Thanks for the breakdown. Maybe a start would be to at least allow updates to the `invertedIndex` -- so if there are a large number of documents, changing a single document doesn't require recreating the entire `invertedIndex`.\r\n\r\nRegarding the `tokenSet`, I wonder if it would be feasible to have an *option* for a non-compressed version that would be easier to update (at the cost of taking extra space). That way you can still have the benefit of space efficiency when mutability is not needed but also cover use cases that require mutability. "}}
{"actor":{"display_login":"abastardi"}}