{"action":"created","issue":{"url":"https://api.github.com/repos/goatslacker/alt/issues/274","labels_url":"https://api.github.com/repos/goatslacker/alt/issues/274/labels{/name}","comments_url":"https://api.github.com/repos/goatslacker/alt/issues/274/comments","events_url":"https://api.github.com/repos/goatslacker/alt/issues/274/events","html_url":"https://github.com/goatslacker/alt/issues/274","id":81824281,"number":274,"title":"Store failed to receive dispatched action","user":{"login":"jimzhan","id":460877,"avatar_url":"https://avatars.githubusercontent.com/u/460877?v=3","gravatar_id":"","url":"https://api.github.com/users/jimzhan","html_url":"https://github.com/jimzhan","followers_url":"https://api.github.com/users/jimzhan/followers","following_url":"https://api.github.com/users/jimzhan/following{/other_user}","gists_url":"https://api.github.com/users/jimzhan/gists{/gist_id}","starred_url":"https://api.github.com/users/jimzhan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jimzhan/subscriptions","organizations_url":"https://api.github.com/users/jimzhan/orgs","repos_url":"https://api.github.com/users/jimzhan/repos","events_url":"https://api.github.com/users/jimzhan/events{/privacy}","received_events_url":"https://api.github.com/users/jimzhan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-28T08:26:05Z","updated_at":"2015-05-28T20:26:42Z","closed_at":null,"body":"**shared/flux.js**\r\n```javascript\r\nimport Alt from 'alt';\r\n\r\nconst flux = new Alt();\r\nexport default flux;\r\n```\r\n\r\n**views/Header.jsx**\r\n```javascript\r\nimport React from 'react';\r\nimport {Link} from 'react-router';\r\n\r\nimport UserActions from '../actions/UserActions';\r\n\r\nexport default class Header extends React.Component {\r\n\r\n  authorize() {\r\n    UserActions.authorize();\r\n  }\r\n\r\n  render() {\r\n    return (\r\n        <header className=\"navbar-fixed\">\r\n          <nav className=\"light-blue darken-4\">\r\n            <div className=\"nav-wrapper container\">\r\n              <a href=\"#!\" className=\"brand-logo\">Logo</a>\r\n              <a href=\"#\" data-activates=\"mobile-demo\" className=\"button-collapse\">\r\n                <i className=\"mdi-navigation-menu\"></i>\r\n              </a>\r\n              <ul className=\"right hide-on-med-and-down\">\r\n                <li>\r\n                  <a href=\"#\" onClick={this.authorize}>\r\n                    <i className=\"fa fa-github fa-2x\"></i>\r\n                  </a>\r\n                <li><Link to=\"home\">Home</Link></li>\r\n                <li><Link to=\"about\">About</Link></li>\r\n                </li>\r\n              </ul>\r\n            </div>\r\n          </nav>\r\n        </header>\r\n    );\r\n  }\r\n}\r\n```\r\n\r\n**actions/UserActions.js**\r\n```javascript\r\nimport flux from '../shared/flux';\r\n\r\nclass UserActions {\r\n  authorize() {\r\n    let url = 'https://github.com/oauth/authorize';\r\n    this.dispatch(url);\r\n    console.log('UserActions.authorize dispatched');\r\n  }\r\n}\r\n\r\nexport default flux.createActions(UserActions);\r\n```\r\n\r\n**stores/UserStore.js**\r\n```javascript\r\nimport flux from '../shared/flux';\r\nimport UserActions from '../actions/UserActions';\r\n\r\n\r\nclass UserStore {\r\n  constructor() {\r\n    this.bindListeners({\r\n      onAuthorize: UserActions.authorize\r\n    });\r\n  }\r\n\r\n  onAuthorize(url) {\r\n    console.log('*** User.authorize ***');\r\n    console.log(url);\r\n  }\r\n}\r\n\r\nexport default flux.createStore(UserStore, 'UserStore');\r\n```"},"comment":{"url":"https://api.github.com/repos/goatslacker/alt/issues/comments/106586206","html_url":"https://github.com/goatslacker/alt/issues/274#issuecomment-106586206","issue_url":"https://api.github.com/repos/goatslacker/alt/issues/274","id":106586206,"user":{"login":"goatslacker","id":10632,"avatar_url":"https://avatars.githubusercontent.com/u/10632?v=3","gravatar_id":"","url":"https://api.github.com/users/goatslacker","html_url":"https://github.com/goatslacker","followers_url":"https://api.github.com/users/goatslacker/followers","following_url":"https://api.github.com/users/goatslacker/following{/other_user}","gists_url":"https://api.github.com/users/goatslacker/gists{/gist_id}","starred_url":"https://api.github.com/users/goatslacker/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/goatslacker/subscriptions","organizations_url":"https://api.github.com/users/goatslacker/orgs","repos_url":"https://api.github.com/users/goatslacker/repos","events_url":"https://api.github.com/users/goatslacker/events{/privacy}","received_events_url":"https://api.github.com/users/goatslacker/received_events","type":"User","site_admin":false},"created_at":"2015-05-28T20:26:42Z","updated_at":"2015-05-28T20:26:42Z","body":"https://gist.github.com/goatslacker/5c2c7b7f9e3433864720"}}