{"action":"opened","issue":{"url":"https://api.github.com/repos/Templarian/ui.bootstrap.contextMenu/issues/7","labels_url":"https://api.github.com/repos/Templarian/ui.bootstrap.contextMenu/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/Templarian/ui.bootstrap.contextMenu/issues/7/comments","events_url":"https://api.github.com/repos/Templarian/ui.bootstrap.contextMenu/issues/7/events","html_url":"https://github.com/Templarian/ui.bootstrap.contextMenu/issues/7","id":59602158,"number":7,"title":"Allow context-menu options from function","user":{"login":"animsakari","id":11287338,"avatar_url":"https://avatars.githubusercontent.com/u/11287338?v=3","gravatar_id":"","url":"https://api.github.com/users/animsakari","html_url":"https://github.com/animsakari","followers_url":"https://api.github.com/users/animsakari/followers","following_url":"https://api.github.com/users/animsakari/following{/other_user}","gists_url":"https://api.github.com/users/animsakari/gists{/gist_id}","starred_url":"https://api.github.com/users/animsakari/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/animsakari/subscriptions","organizations_url":"https://api.github.com/users/animsakari/orgs","repos_url":"https://api.github.com/users/animsakari/repos","events_url":"https://api.github.com/users/animsakari/events{/privacy}","received_events_url":"https://api.github.com/users/animsakari/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-03-03T06:42:52Z","updated_at":"2015-03-03T06:42:52Z","closed_at":null,"body":"Being able to generate menu options dynamically might be useful.  One way to do this would be to allow context-menu to be assigned either an array or a scope function that returned the same type of array.  If the function was passed the menu scope, a developer could make the menu dynamic based on the specific scope and its current state.\r\nSomething like... Line 71:\r\n                } else if (typeof options === 'function') {\r\n                    renderContextMenu($scope, event, options($scope));\r\n                } else..."}}