Githtml - View Html Files from Github Repos On The Fly
1–10 of 22 posts
Re: Githtml - View Html Files from Github Repos On The Fly
#2I mean, it has virtually nothing to do with git.
Re: Githtml - View Html Files from Github Repos On The Fly
#3Re: Githtml - View Html Files from Github Repos On The Fly
#4the rendered pages are not very accurate, they seem deformed.
Re: Githtml - View Html Files from Github Repos On The Fly
#5If you want to use it you should fork it and change to bookmarklet to use your fork of the js file.
Re: Githtml - View Html Files from Github Repos On The Fly
#6 javascript:void(document.body.innerHTML = document.getElementsByTagName("pre")[0].innerHTML.replace(/&/g,"&").replace(/</g,"").replace(/ /g," "));
(Note: I've only tested this on Chrome.)Re: Githtml - View Html Files from Github Repos On The Fly
#7This seems like a lot of code... Here's what I use: javascript:void(document.body.innerHTML = document.getElementsByTagName("pre")[0].innerHTML.replace(/&/g,"&").replace(/</g," ").replace(/ /g," ")); (Note: I've only tested this on Chrome.)
Try your code on this page: https://raw.github.com/mrdoob/three.js/46c0a8434d3f269741a88...
And compare it with githtml on the /blob/ version of the same page: https://github.com/mrdoob/three.js/blob/master/examples/canv...
Re: Githtml - View Html Files from Github Repos On The Fly
#8Re: Githtml - View Html Files from Github Repos On The Fly
#9This has a really big security flaw, if the creator wanted to be mischievous he could change his js file to do things to your logged in github account, for example set your privet repositories public. If you want to use it you should fork it and change to bookmarklet to use your fork of the js file.
Re: Githtml - View Html Files from Github Repos On The Fly
#10This seems like a lot of code... Here's what I use: javascript:void(document.body.innerHTML = document.getElementsByTagName("pre")[0].innerHTML.replace(/&/g,"&").replace(/</g," ").replace(/ /g," ")); (Note: I've only tested this on Chrome.)
Most of the code is for mapping css and js files to the relative raw pages. Try your code on this page: https://raw.github.com/mrdoob/three.js/46c0a8434d3f269741a88... And compare it with githtml on the /blob/ version of the same page: https://github.com/mrdoob/three.js/blob/master/examples/canv...
I suspect that JS that didn't depend on the page-load to trigger it would work too. I had never considered looking at JS-enabled pages though. When I wrote my bookmarklet, I just needed to view static documentation.
Edit: I found a page with only on-click JS events, and they didn't work. Oh well...