{"action":"created","issue":{"url":"https://api.github.com/repos/johnnyfreeman/winston/issues/9","labels_url":"https://api.github.com/repos/johnnyfreeman/winston/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/johnnyfreeman/winston/issues/9/comments","events_url":"https://api.github.com/repos/johnnyfreeman/winston/issues/9/events","html_url":"https://github.com/johnnyfreeman/winston/issues/9","id":63842375,"number":9,"title":"Handle bookmark folders","user":{"login":"srudisill","id":10853414,"avatar_url":"https://avatars.githubusercontent.com/u/10853414?v=3","gravatar_id":"","url":"https://api.github.com/users/srudisill","html_url":"https://github.com/srudisill","followers_url":"https://api.github.com/users/srudisill/followers","following_url":"https://api.github.com/users/srudisill/following{/other_user}","gists_url":"https://api.github.com/users/srudisill/gists{/gist_id}","starred_url":"https://api.github.com/users/srudisill/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srudisill/subscriptions","organizations_url":"https://api.github.com/users/srudisill/orgs","repos_url":"https://api.github.com/users/srudisill/repos","events_url":"https://api.github.com/users/srudisill/events{/privacy}","received_events_url":"https://api.github.com/users/srudisill/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-23T21:53:03Z","updated_at":"2015-03-23T23:11:36Z","closed_at":null,"body":"Chrome supports bookmark folders. Maybe list the bookmarks within that folder if the search matches?"},"comment":{"url":"https://api.github.com/repos/johnnyfreeman/winston/issues/comments/85243040","html_url":"https://github.com/johnnyfreeman/winston/issues/9#issuecomment-85243040","issue_url":"https://api.github.com/repos/johnnyfreeman/winston/issues/9","id":85243040,"user":{"login":"johnnyfreeman","id":371481,"avatar_url":"https://avatars.githubusercontent.com/u/371481?v=3","gravatar_id":"","url":"https://api.github.com/users/johnnyfreeman","html_url":"https://github.com/johnnyfreeman","followers_url":"https://api.github.com/users/johnnyfreeman/followers","following_url":"https://api.github.com/users/johnnyfreeman/following{/other_user}","gists_url":"https://api.github.com/users/johnnyfreeman/gists{/gist_id}","starred_url":"https://api.github.com/users/johnnyfreeman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnnyfreeman/subscriptions","organizations_url":"https://api.github.com/users/johnnyfreeman/orgs","repos_url":"https://api.github.com/users/johnnyfreeman/repos","events_url":"https://api.github.com/users/johnnyfreeman/events{/privacy}","received_events_url":"https://api.github.com/users/johnnyfreeman/received_events","type":"User","site_admin":false},"created_at":"2015-03-23T23:11:36Z","updated_at":"2015-03-23T23:11:36Z","body":"Good catch @srudisill!\r\n\r\nMy first thought was, when you are typing the name of a bookmark folder, to open that folder. However, the [chrome.bookmarks api](https://developer.chrome.com/extensions/bookmarks) doesn't appear to offer any way to do that.\r\n\r\nWhen I inspect the bookmark result [from here](https://github.com/johnnyfreeman/winston/blob/master/src/js/bookmarks.js#L18), this is what is returned for a _folder_:\r\n\r\n```javascript\r\n{\r\n    dateAdded: 1379855896022,\r\n    dateGroupModified: 1416522864648,\r\n    id: \"55\",\r\n    index: 6,\r\n    parentId: \"1\",\r\n    title: \"Tattoos\"\r\n}\r\n```\r\n\r\nAnd this for a child _bookmark_ of that folder:\r\n\r\n```javascript\r\n{\r\n    dateAdded: 1379902475572,\r\n    id: \"58\",\r\n    index: 0,\r\n    parentId: \"55\",\r\n    title: \"full-sleeve-tattoo-designs\",\r\n    url: \"http://tattooideasmag.com/extreme-full-sleeve-tattoos/full-sleeve-tattoo-designs/\"\r\n}\r\n```\r\n\r\nSo what is the proper way to handle a query for a folder? It seems like the options are to either:\r\n\r\na) Not include bookmark results where `bookmark.url` is `undefined`.\r\nb) Do another (nested) search query for all the child bookmarks where `child.parentId` == `parent.id`\r\n\r\nI go back and forth. On one hand, a package should try to give you the most accurate/relevant results matching your input string. So returning the children of what you're looking seems contradictory to that idea. On the other hand, I think it _should_ be left up the the package itself to determine what _is_ accurate or relevant to your input string.\r\n\r\nThoughts?"}}