{"action":"created","issue":{"url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/136","labels_url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/136/labels{/name}","comments_url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/136/comments","events_url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/136/events","html_url":"https://github.com/elm-lang/package.elm-lang.org/pull/136","id":119279768,"number":136,"title":"Preview package documentation on site","user":{"login":"burabure","id":3132298,"avatar_url":"https://avatars.githubusercontent.com/u/3132298?v=3","gravatar_id":"","url":"https://api.github.com/users/burabure","html_url":"https://github.com/burabure","followers_url":"https://api.github.com/users/burabure/followers","following_url":"https://api.github.com/users/burabure/following{/other_user}","gists_url":"https://api.github.com/users/burabure/gists{/gist_id}","starred_url":"https://api.github.com/users/burabure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/burabure/subscriptions","organizations_url":"https://api.github.com/users/burabure/orgs","repos_url":"https://api.github.com/users/burabure/repos","events_url":"https://api.github.com/users/burabure/events{/privacy}","received_events_url":"https://api.github.com/users/burabure/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":25,"created_at":"2015-11-28T08:04:06Z","updated_at":"2015-12-12T05:55:53Z","closed_at":"2015-12-01T22:15:15Z","pull_request":{"url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/pulls/136","html_url":"https://github.com/elm-lang/package.elm-lang.org/pull/136","diff_url":"https://github.com/elm-lang/package.elm-lang.org/pull/136.diff","patch_url":"https://github.com/elm-lang/package.elm-lang.org/pull/136.patch"},"body":"# Motivation\r\n\r\nA common request from package authors is \"How can I see the docs before I publish my package?\" Like in this issue https://github.com/elm-lang/elm-lang.org/issues/169.\r\n\r\nMy solution creates a \"Preview your Documentation\" page that takes a .json documentation file from elm-make via a file input, loads it locally using the js File API, parses it with the existing document parsers and displays the formatted documentation\r\n\r\n# What I changed\r\n\r\n- Added a new route for \"tools/preview-documentation\" on the server\r\n- Added links to the tool in the Resources sidebar, API Design Guidelines and Documentation Format pages.\r\n- Added list styles to the Resources sidebar to prevent confusion when reading 2+ text lines items\r\n- Added a \"tools\" tag type  in ```Route.elm``` and displays text for the header in\r\n- Created PreviewDocumentation.elm with the necessary logic for the tool\r\n- Created an ```/assets/js/jsonLoader.js``` file to handle the needed native js File API logic\r\n- Added ```new-packages.json``` to .gitignore because it seems to be a good idea ;D\r\n\r\nI'm just learning Elm and I'd love any suggestions or feedback about the code, implementation or overall solution"},"comment":{"url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/comments/164113773","html_url":"https://github.com/elm-lang/package.elm-lang.org/pull/136#issuecomment-164113773","issue_url":"https://api.github.com/repos/elm-lang/package.elm-lang.org/issues/136","id":164113773,"user":{"login":"burabure","id":3132298,"avatar_url":"https://avatars.githubusercontent.com/u/3132298?v=3","gravatar_id":"","url":"https://api.github.com/users/burabure","html_url":"https://github.com/burabure","followers_url":"https://api.github.com/users/burabure/followers","following_url":"https://api.github.com/users/burabure/following{/other_user}","gists_url":"https://api.github.com/users/burabure/gists{/gist_id}","starred_url":"https://api.github.com/users/burabure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/burabure/subscriptions","organizations_url":"https://api.github.com/users/burabure/orgs","repos_url":"https://api.github.com/users/burabure/repos","events_url":"https://api.github.com/users/burabure/events{/privacy}","received_events_url":"https://api.github.com/users/burabure/received_events","type":"User","site_admin":false},"created_at":"2015-12-12T05:55:53Z","updated_at":"2015-12-12T05:55:53Z","body":"@evancz I've merged the changes here https://github.com/burabure/package.elm-lang.org/tree/diffs\r\n\r\nI think the context I've added to https://github.com/burabure/package.elm-lang.org/blob/diffs/src/frontend/Docs/Name.elm could replace the \"isNormal\" flag, but I decided that it would be better if you take a look at it =)\r\n\r\nhttps://github.com/burabure/package.elm-lang.org/blob/diffs/src/frontend/Page/PackageOverview.elm#L386-L392\r\n\r\nPS: the diff feature is looking awesome!!!, it's definetly going to be really useful!"}}