Mohsen
Mohsen

Reputation: 65775

How to make a page render in browser in Github?

If I have an .html page in my project and want to show that as it's renders what should I do? Is there any specific URL for this reason?

Update: In Github I mean!

Upvotes: 2

Views: 4905

Answers (3)

sdasara
sdasara

Reputation: 107

This can be done using the following steps:

  1. Rename the .html file to index.html
  2. Go to setting and enable Github Pages for master branch.
  3. Go to the website:
   https://username.github.io/repo-name/

Here you put your username and repository name containing the html file

Upvotes: 1

Vijay
Vijay

Reputation: 501

This solution only for chrome browser. I am not sure about other browser.

  1. Add "Modify Content-Type Options" extension in chrome browser.
  2. Open "chrome-extension://jnfofbopfpaoeojgieggflbpcblhfhka/options.html" url in browser.
  3. Add the rule for raw file url. For example:
    • URL Filter: https:///raw/master//fileName.html
    • Original Type: text/plain
    • Replacement Type: text/html
  4. Open the file browser which you added url in rule (in step 3).

Upvotes: 0

niutech
niutech

Reputation: 29922

The easiest way is to use GitHub HTML Preview

Upvotes: 1

Related Questions