{"action":"created","comment":{"url":"https://api.github.com/repos/massgov/mayflower-react/pulls/comments/165722773","pull_request_review_id":93712527,"id":165722773,"diff_hunk":"@@ -23,3 +23,35 @@\n - `npm run build` will build the component for publishing to npm and also bundle the demo app.\n \n - `npm run clean` will delete built resources.\n+\n+## Creating New Components\n+Follow these mayflower-react component [road runner rules](http://thechive.com/2015/03/10/chuck-jones-9-unbreakable-rules-for-the-coyote-and-the-road-runner-cartoon-series-10-photos/):","path":"CONTRIBUTING.md","position":6,"original_position":6,"commit_id":"893b5407d7aebbb67ab8895e4d07702fde7ae94f","original_commit_id":"893b5407d7aebbb67ab8895e4d07702fde7ae94f","user":{"login":"mrjmd","id":2111857,"avatar_url":"https://avatars1.githubusercontent.com/u/2111857?v=4","gravatar_id":"","url":"https://api.github.com/users/mrjmd","html_url":"https://github.com/mrjmd","followers_url":"https://api.github.com/users/mrjmd/followers","following_url":"https://api.github.com/users/mrjmd/following{/other_user}","gists_url":"https://api.github.com/users/mrjmd/gists{/gist_id}","starred_url":"https://api.github.com/users/mrjmd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrjmd/subscriptions","organizations_url":"https://api.github.com/users/mrjmd/orgs","repos_url":"https://api.github.com/users/mrjmd/repos","events_url":"https://api.github.com/users/mrjmd/events{/privacy}","received_events_url":"https://api.github.com/users/mrjmd/received_events","type":"User","site_admin":false},"body":"Woohoo this documentation is awesome!","created_at":"2018-02-02T18:31:30Z","updated_at":"2018-02-02T18:31:30Z","html_url":"https://github.com/massgov/mayflower-react/pull/16#discussion_r165722773","pull_request_url":"https://api.github.com/repos/massgov/mayflower-react/pulls/16","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/comments/165722773"},"html":{"href":"https://github.com/massgov/mayflower-react/pull/16#discussion_r165722773"},"pull_request":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/16"}}},"pull_request":{"url":"https://api.github.com/repos/massgov/mayflower-react/pulls/16","id":166418089,"html_url":"https://github.com/massgov/mayflower-react/pull/16","diff_url":"https://github.com/massgov/mayflower-react/pull/16.diff","patch_url":"https://github.com/massgov/mayflower-react/pull/16.patch","issue_url":"https://api.github.com/repos/massgov/mayflower-react/issues/16","number":16,"state":"open","locked":false,"title":"Golden pattern template: button","user":{"login":"jesconstantine","id":3279883,"avatar_url":"https://avatars3.githubusercontent.com/u/3279883?v=4","gravatar_id":"","url":"https://api.github.com/users/jesconstantine","html_url":"https://github.com/jesconstantine","followers_url":"https://api.github.com/users/jesconstantine/followers","following_url":"https://api.github.com/users/jesconstantine/following{/other_user}","gists_url":"https://api.github.com/users/jesconstantine/gists{/gist_id}","starred_url":"https://api.github.com/users/jesconstantine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jesconstantine/subscriptions","organizations_url":"https://api.github.com/users/jesconstantine/orgs","repos_url":"https://api.github.com/users/jesconstantine/repos","events_url":"https://api.github.com/users/jesconstantine/events{/privacy}","received_events_url":"https://api.github.com/users/jesconstantine/received_events","type":"User","site_admin":false},"body":"Proposed mayflower-react component [road runner rules](http://thechive.com/2015/03/10/chuck-jones-9-unbreakable-rules-for-the-coyote-and-the-road-runner-cartoon-series-10-photos/):\r\n\r\n1. Parent paths match those of mayflower: `atoms/buttons/` with the exception of `organisms/by-*` which we will ignore (i.e. all organism component folders live in the organisms folder)\r\n1. Component has it's own folder, the name is a capital CamelCase version of the pattern name: `Button/`\r\n1. The component is the capital CamelCase version of the pattern name: `<Button />`\r\n1. Component folder as follows:\r\n```\r\nButton/\r\n├── index.js (Component file)\r\n├── Button.stories.js (Component story file)\r\n└── Button.knobs.options.js (Any enumerable prop options that can be imported in story files)\r\n```\r\n1. In the Component file:\r\n    1. Default to `const` over `class` -- these should be simple components which can get implemented in other apps via `class` with lifecycle methods and with redux `connect`.\r\n    1. Set `.defaultProps` **only for non-required** configuration variables which need to be \"opted in\" to activate (i.e. the pattern would render like the pattern page in mayflower sans content -- see [button for example](https://github.com/massgov/mayflower-react/pull/16/files#diff-71d699cd557ebf06db4e0d195497642cR44))\r\n    1. Do not set `.defaultProps` for content variables.\r\n    1. Set `.defaultProps` **only for non-required** child components referenced by parent components equal to the existing `.defaultProps` used in child components.\r\n    1. `props` are namespaced with the camelCase version of the component via declaration (but not defined as a prop key): `const button = this.props` and subsequently referenced by `button.propname` (as it appears in twig template).\r\n    1. prop types defined (consult the pattern .md file in mayflower) and documented with comment (this will show up in the story props table):\r\n    ```\r\n\t...\r\n\t/** My prop description */\r\n    myProp: PropType.type,\r\n\t...\r\n    ```\r\n1. In the Story file:\r\n    1. Use `withInfo` to pull in an externally authored `.md` docs file to describe the Component (see pattern .md file in mayflower) and link to the mayflower front end version\r\n        1. Wrap the markdown variable in `<div></div>` to ensure the html is rendered (and not printed) - see [button example](https://github.com/massgov/mayflower-react/pull/16/commits/db152f0fe09f77376e1bea82de05bbcd6543d8f5)\r\n    1. Abstract away knob objects for any enumerable properties (so we can import them in the story file for any component which references this one)\r\n    1. Assign `props const` in json structure and render component by passing props via object spread: `<Button {...props}`","created_at":"2018-02-01T00:59:36Z","updated_at":"2018-02-02T18:31:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"20e97aea96c628d166e4e5c3b8e08dd400588351","assignee":null,"assignees":[],"requested_reviewers":[{"login":"smurrayatwork","id":5257660,"avatar_url":"https://avatars1.githubusercontent.com/u/5257660?v=4","gravatar_id":"","url":"https://api.github.com/users/smurrayatwork","html_url":"https://github.com/smurrayatwork","followers_url":"https://api.github.com/users/smurrayatwork/followers","following_url":"https://api.github.com/users/smurrayatwork/following{/other_user}","gists_url":"https://api.github.com/users/smurrayatwork/gists{/gist_id}","starred_url":"https://api.github.com/users/smurrayatwork/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smurrayatwork/subscriptions","organizations_url":"https://api.github.com/users/smurrayatwork/orgs","repos_url":"https://api.github.com/users/smurrayatwork/repos","events_url":"https://api.github.com/users/smurrayatwork/events{/privacy}","received_events_url":"https://api.github.com/users/smurrayatwork/received_events","type":"User","site_admin":false},{"login":"avrilpearl","id":9359261,"avatar_url":"https://avatars1.githubusercontent.com/u/9359261?v=4","gravatar_id":"","url":"https://api.github.com/users/avrilpearl","html_url":"https://github.com/avrilpearl","followers_url":"https://api.github.com/users/avrilpearl/followers","following_url":"https://api.github.com/users/avrilpearl/following{/other_user}","gists_url":"https://api.github.com/users/avrilpearl/gists{/gist_id}","starred_url":"https://api.github.com/users/avrilpearl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/avrilpearl/subscriptions","organizations_url":"https://api.github.com/users/avrilpearl/orgs","repos_url":"https://api.github.com/users/avrilpearl/repos","events_url":"https://api.github.com/users/avrilpearl/events{/privacy}","received_events_url":"https://api.github.com/users/avrilpearl/received_events","type":"User","site_admin":false},{"login":"iansholtys","id":18170074,"avatar_url":"https://avatars1.githubusercontent.com/u/18170074?v=4","gravatar_id":"","url":"https://api.github.com/users/iansholtys","html_url":"https://github.com/iansholtys","followers_url":"https://api.github.com/users/iansholtys/followers","following_url":"https://api.github.com/users/iansholtys/following{/other_user}","gists_url":"https://api.github.com/users/iansholtys/gists{/gist_id}","starred_url":"https://api.github.com/users/iansholtys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iansholtys/subscriptions","organizations_url":"https://api.github.com/users/iansholtys/orgs","repos_url":"https://api.github.com/users/iansholtys/repos","events_url":"https://api.github.com/users/iansholtys/events{/privacy}","received_events_url":"https://api.github.com/users/iansholtys/received_events","type":"User","site_admin":false}],"requested_teams":[],"milestone":null,"commits_url":"https://api.github.com/repos/massgov/mayflower-react/pulls/16/commits","review_comments_url":"https://api.github.com/repos/massgov/mayflower-react/pulls/16/comments","review_comment_url":"https://api.github.com/repos/massgov/mayflower-react/pulls/comments{/number}","comments_url":"https://api.github.com/repos/massgov/mayflower-react/issues/16/comments","statuses_url":"https://api.github.com/repos/massgov/mayflower-react/statuses/893b5407d7aebbb67ab8895e4d07702fde7ae94f","head":{"label":"massgov:button-golden","ref":"button-golden","sha":"893b5407d7aebbb67ab8895e4d07702fde7ae94f","user":{"login":"massgov","id":7770800,"avatar_url":"https://avatars3.githubusercontent.com/u/7770800?v=4","gravatar_id":"","url":"https://api.github.com/users/massgov","html_url":"https://github.com/massgov","followers_url":"https://api.github.com/users/massgov/followers","following_url":"https://api.github.com/users/massgov/following{/other_user}","gists_url":"https://api.github.com/users/massgov/gists{/gist_id}","starred_url":"https://api.github.com/users/massgov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/massgov/subscriptions","organizations_url":"https://api.github.com/users/massgov/orgs","repos_url":"https://api.github.com/users/massgov/repos","events_url":"https://api.github.com/users/massgov/events{/privacy}","received_events_url":"https://api.github.com/users/massgov/received_events","type":"Organization","site_admin":false},"repo":{"id":118505307,"name":"mayflower-react","full_name":"massgov/mayflower-react","owner":{"login":"massgov","id":7770800,"avatar_url":"https://avatars3.githubusercontent.com/u/7770800?v=4","gravatar_id":"","url":"https://api.github.com/users/massgov","html_url":"https://github.com/massgov","followers_url":"https://api.github.com/users/massgov/followers","following_url":"https://api.github.com/users/massgov/following{/other_user}","gists_url":"https://api.github.com/users/massgov/gists{/gist_id}","starred_url":"https://api.github.com/users/massgov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/massgov/subscriptions","organizations_url":"https://api.github.com/users/massgov/orgs","repos_url":"https://api.github.com/users/massgov/repos","events_url":"https://api.github.com/users/massgov/events{/privacy}","received_events_url":"https://api.github.com/users/massgov/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/massgov/mayflower-react","description":"A react component library for the Mayflower design system","fork":false,"url":"https://api.github.com/repos/massgov/mayflower-react","forks_url":"https://api.github.com/repos/massgov/mayflower-react/forks","keys_url":"https://api.github.com/repos/massgov/mayflower-react/keys{/key_id}","collaborators_url":"https://api.github.com/repos/massgov/mayflower-react/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/massgov/mayflower-react/teams","hooks_url":"https://api.github.com/repos/massgov/mayflower-react/hooks","issue_events_url":"https://api.github.com/repos/massgov/mayflower-react/issues/events{/number}","events_url":"https://api.github.com/repos/massgov/mayflower-react/events","assignees_url":"https://api.github.com/repos/massgov/mayflower-react/assignees{/user}","branches_url":"https://api.github.com/repos/massgov/mayflower-react/branches{/branch}","tags_url":"https://api.github.com/repos/massgov/mayflower-react/tags","blobs_url":"https://api.github.com/repos/massgov/mayflower-react/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/massgov/mayflower-react/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/massgov/mayflower-react/git/refs{/sha}","trees_url":"https://api.github.com/repos/massgov/mayflower-react/git/trees{/sha}","statuses_url":"https://api.github.com/repos/massgov/mayflower-react/statuses/{sha}","languages_url":"https://api.github.com/repos/massgov/mayflower-react/languages","stargazers_url":"https://api.github.com/repos/massgov/mayflower-react/stargazers","contributors_url":"https://api.github.com/repos/massgov/mayflower-react/contributors","subscribers_url":"https://api.github.com/repos/massgov/mayflower-react/subscribers","subscription_url":"https://api.github.com/repos/massgov/mayflower-react/subscription","commits_url":"https://api.github.com/repos/massgov/mayflower-react/commits{/sha}","git_commits_url":"https://api.github.com/repos/massgov/mayflower-react/git/commits{/sha}","comments_url":"https://api.github.com/repos/massgov/mayflower-react/comments{/number}","issue_comment_url":"https://api.github.com/repos/massgov/mayflower-react/issues/comments{/number}","contents_url":"https://api.github.com/repos/massgov/mayflower-react/contents/{+path}","compare_url":"https://api.github.com/repos/massgov/mayflower-react/compare/{base}...{head}","merges_url":"https://api.github.com/repos/massgov/mayflower-react/merges","archive_url":"https://api.github.com/repos/massgov/mayflower-react/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/massgov/mayflower-react/downloads","issues_url":"https://api.github.com/repos/massgov/mayflower-react/issues{/number}","pulls_url":"https://api.github.com/repos/massgov/mayflower-react/pulls{/number}","milestones_url":"https://api.github.com/repos/massgov/mayflower-react/milestones{/number}","notifications_url":"https://api.github.com/repos/massgov/mayflower-react/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/massgov/mayflower-react/labels{/name}","releases_url":"https://api.github.com/repos/massgov/mayflower-react/releases{/id}","deployments_url":"https://api.github.com/repos/massgov/mayflower-react/deployments","created_at":"2018-01-22T19:36:31Z","updated_at":"2018-01-25T00:39:19Z","pushed_at":"2018-02-02T18:22:24Z","git_url":"git://github.com/massgov/mayflower-react.git","ssh_url":"git@github.com:massgov/mayflower-react.git","clone_url":"https://github.com/massgov/mayflower-react.git","svn_url":"https://github.com/massgov/mayflower-react","homepage":"","size":576,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":1,"default_branch":"develop"}},"base":{"label":"massgov:develop","ref":"develop","sha":"ba1a0a8cc56a666a3b5d79a3160dd3b0e988417b","user":{"login":"massgov","id":7770800,"avatar_url":"https://avatars3.githubusercontent.com/u/7770800?v=4","gravatar_id":"","url":"https://api.github.com/users/massgov","html_url":"https://github.com/massgov","followers_url":"https://api.github.com/users/massgov/followers","following_url":"https://api.github.com/users/massgov/following{/other_user}","gists_url":"https://api.github.com/users/massgov/gists{/gist_id}","starred_url":"https://api.github.com/users/massgov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/massgov/subscriptions","organizations_url":"https://api.github.com/users/massgov/orgs","repos_url":"https://api.github.com/users/massgov/repos","events_url":"https://api.github.com/users/massgov/events{/privacy}","received_events_url":"https://api.github.com/users/massgov/received_events","type":"Organization","site_admin":false},"repo":{"id":118505307,"name":"mayflower-react","full_name":"massgov/mayflower-react","owner":{"login":"massgov","id":7770800,"avatar_url":"https://avatars3.githubusercontent.com/u/7770800?v=4","gravatar_id":"","url":"https://api.github.com/users/massgov","html_url":"https://github.com/massgov","followers_url":"https://api.github.com/users/massgov/followers","following_url":"https://api.github.com/users/massgov/following{/other_user}","gists_url":"https://api.github.com/users/massgov/gists{/gist_id}","starred_url":"https://api.github.com/users/massgov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/massgov/subscriptions","organizations_url":"https://api.github.com/users/massgov/orgs","repos_url":"https://api.github.com/users/massgov/repos","events_url":"https://api.github.com/users/massgov/events{/privacy}","received_events_url":"https://api.github.com/users/massgov/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/massgov/mayflower-react","description":"A react component library for the Mayflower design system","fork":false,"url":"https://api.github.com/repos/massgov/mayflower-react","forks_url":"https://api.github.com/repos/massgov/mayflower-react/forks","keys_url":"https://api.github.com/repos/massgov/mayflower-react/keys{/key_id}","collaborators_url":"https://api.github.com/repos/massgov/mayflower-react/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/massgov/mayflower-react/teams","hooks_url":"https://api.github.com/repos/massgov/mayflower-react/hooks","issue_events_url":"https://api.github.com/repos/massgov/mayflower-react/issues/events{/number}","events_url":"https://api.github.com/repos/massgov/mayflower-react/events","assignees_url":"https://api.github.com/repos/massgov/mayflower-react/assignees{/user}","branches_url":"https://api.github.com/repos/massgov/mayflower-react/branches{/branch}","tags_url":"https://api.github.com/repos/massgov/mayflower-react/tags","blobs_url":"https://api.github.com/repos/massgov/mayflower-react/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/massgov/mayflower-react/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/massgov/mayflower-react/git/refs{/sha}","trees_url":"https://api.github.com/repos/massgov/mayflower-react/git/trees{/sha}","statuses_url":"https://api.github.com/repos/massgov/mayflower-react/statuses/{sha}","languages_url":"https://api.github.com/repos/massgov/mayflower-react/languages","stargazers_url":"https://api.github.com/repos/massgov/mayflower-react/stargazers","contributors_url":"https://api.github.com/repos/massgov/mayflower-react/contributors","subscribers_url":"https://api.github.com/repos/massgov/mayflower-react/subscribers","subscription_url":"https://api.github.com/repos/massgov/mayflower-react/subscription","commits_url":"https://api.github.com/repos/massgov/mayflower-react/commits{/sha}","git_commits_url":"https://api.github.com/repos/massgov/mayflower-react/git/commits{/sha}","comments_url":"https://api.github.com/repos/massgov/mayflower-react/comments{/number}","issue_comment_url":"https://api.github.com/repos/massgov/mayflower-react/issues/comments{/number}","contents_url":"https://api.github.com/repos/massgov/mayflower-react/contents/{+path}","compare_url":"https://api.github.com/repos/massgov/mayflower-react/compare/{base}...{head}","merges_url":"https://api.github.com/repos/massgov/mayflower-react/merges","archive_url":"https://api.github.com/repos/massgov/mayflower-react/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/massgov/mayflower-react/downloads","issues_url":"https://api.github.com/repos/massgov/mayflower-react/issues{/number}","pulls_url":"https://api.github.com/repos/massgov/mayflower-react/pulls{/number}","milestones_url":"https://api.github.com/repos/massgov/mayflower-react/milestones{/number}","notifications_url":"https://api.github.com/repos/massgov/mayflower-react/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/massgov/mayflower-react/labels{/name}","releases_url":"https://api.github.com/repos/massgov/mayflower-react/releases{/id}","deployments_url":"https://api.github.com/repos/massgov/mayflower-react/deployments","created_at":"2018-01-22T19:36:31Z","updated_at":"2018-01-25T00:39:19Z","pushed_at":"2018-02-02T18:22:24Z","git_url":"git://github.com/massgov/mayflower-react.git","ssh_url":"git@github.com:massgov/mayflower-react.git","clone_url":"https://github.com/massgov/mayflower-react.git","svn_url":"https://github.com/massgov/mayflower-react","homepage":"","size":576,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":1,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/16"},"html":{"href":"https://github.com/massgov/mayflower-react/pull/16"},"issue":{"href":"https://api.github.com/repos/massgov/mayflower-react/issues/16"},"comments":{"href":"https://api.github.com/repos/massgov/mayflower-react/issues/16/comments"},"review_comments":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/16/comments"},"review_comment":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/massgov/mayflower-react/pulls/16/commits"},"statuses":{"href":"https://api.github.com/repos/massgov/mayflower-react/statuses/893b5407d7aebbb67ab8895e4d07702fde7ae94f"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"mrjmd"}}