
GitHubDocs – Open source SPA built using Markdown docs in your GitHub repo - mrvautin
https://www.npmjs.com/package/githubdocs
======
t3f
Seems to break my back button.

Going to [0] then redirects me to [1] and single presses of back continuously
redirect from [0] to [1].

[0] [https://githubdocs.markmoffat.com/](https://githubdocs.markmoffat.com/)

[1] [https://githubdocs.markmoffat.com/#Erant-ventorum-aliter-
ess...](https://githubdocs.markmoffat.com/#Erant-ventorum-aliter-esse-
pervenientia-mutua-numquam)

------
xj9
pls stop

you already have an html _document_ and a _browser_ that was made for
_browsing_ documents. why make _another_ application that does the job of the
application i'm using to access your documents?

for fun, it get it, but as far as something that i would actually use to read
docs. no thanks.

------
petepete
Search doesn't look like it's working on the example site. When I pick a word
at random from the text body and search for it there are no results.

~~~
mrvautin
Thanks. I will check it out.

------
kronos29296
Soon this will become an offline app in electron which can be used as offline
reference. Instead of a readme or html help. (Sometimes progress isn't a
feature but a lack of)

------
numbsafari
Why would I want an SPA for documentation?

~~~
mrvautin
Why not?

~~~
detaro
Because being an SPA adds tons of potential for bugs that normal sites don't
have. Case in point, your demo:

\- required changing my adblocker settings to work

\- Breaks the back button on the first page by adding instead of replacing the
start page on the history stack

\- changing pages doesn't reset the scroll position - you jump to somewhere in
the middle of the new page if you switch pages while scrolled down

All of these can be fixed, but a non-SPA wouldn't have any of them in the
first place. More work for what benefit exactly?

(While I'm listing bugs, the top of the content scrollbar is cut off/hidden
behind the top bar, but that's not SPA specific)

~~~
spilk
Plus it's (more) complicated to wget mirror it to reference while offline.
Being in a public github repo makes it easy but I've run into issues trying to
take older frames-based "SPA" documentation sites offline that aren't
explicitly downloadable.

------
pspeter3
Why not use gitbook?

~~~
stephenr
Genuine question: isn't that targeted at writing (and then publishing)
_actual_ books, rather than relatively (compared to a book) short
documentation?

~~~
pspeter3
It is but it is also used for documentation. The Redux documentation use
gitbook for example [http://redux.js.org/](http://redux.js.org/)

------
guessmyname
At this point, I think JavaScript programmers are just trolling.

The argument that _" because others are doing SPAs, we have to do too"_ is
invalid, the _" others"_ are just either your friends or popular JavaScript
programmers, and you follow them because you lack better arguments to go
against this development technique. An SPA adds unexpected behavior to every
web application, when we have spent years learning how a popular web browser
behaves, people come to re-invent the wheel _(back buttons, custom scroll
bars, custom routers, and who knows what else)_.

Normally, I encourage people to learn and work on whatever thing they are
interested in, not just technology-wise. But when you start promoting your
project trying to make people use it as if it was good, well, then you have to
expect some rants here and there. I am sure there is a lot of people who would
disagree with me, and people who have good arguments for the development of an
SPA, I would love to hear those arguments, I am being serious.

~~~
ameliaquining
The primary argument in favor of SPAs is that otherwise the entire page and
every resource on it has to be reloaded every time the user navigates, and the
resulting user experience is vastly inferior to that of an SPA (or native
app), especially for users on low-end devices and/or high-latency connections.

~~~
stephenr
> every resource on it has to be reloaded every time the user navigates

Since when? Browser cache is a thing that exists.

> especially for users on low-end devices and/or high-latency connections

I use an original iPad Mini (so basically the guts of an iPad 2 with a smaller
screen) for occasional browsing. It definitely works better on simple, JS free
pages.

I use said iPad Mini in Thailand. Regardless of our ISP provided line-speed,
connections out of the country are always a throttling point for data. Having
a regular browser-provided loading indicator (which can actually be
intelligent and use things like the Content-Length header) is definitely
preferable to some in-page JS (see above) spinner that gives zero indication
of what % is loaded, or if it's hung, or whatever.

I am convinced at this point that SPA's basically exist to be 'portfolio'
sites for front-end developers, the way designers would (maybe still do)
create their own take on a popular app/website/etc and publish it, to show off
what they're capable of.

