Live data from Hacker News

HTML6 proposal for single-page apps without JavaScript

lists.w3.org

21–30 of 177 posts

Re: HTML6 proposal for single-page apps without JavaScript

#22
post #10

I'm not necessarily opposed to something along these lines, except that it's basically already been tried: XSLT was essentially the inverse of this, where data endpoints were annotated with some static rendering descriptors. To me the XSLT approach seems cleaner, in that the URLs the browser is visiting are for the raw data itself, the URL scheme between machine and human is identical, and so on. XSLT also encouraged…

Yep. I used to love XSLT -- working in it finally forced me to understand recursion at, like, a deep cellular level -- but the whole time I was using it I knew it was a doomed language (because most people don't want to have to understand recursion at a deep cellular level just to be able to lay out a damn web page.)

Re: HTML6 proposal for single-page apps without JavaScript

#23
Single page apps seem like a hack to make browser apps feel like they are closer to native apps. Because most SPAs have a set flow, it seems like we should be able to use prefetching to tell the browser what is most likely to happen next. For example, if you are on a list, then you can tell the browser to prefetch the details.

What I feel like is missing from this equation is a nice transition between pages. How nice would it be to have something like this:

Details

If the browser prefetched the details and handled the transition, I would see no need for an SPA. We would get the benefits without having to implement a hack.

Re: HTML6 proposal for single-page apps without JavaScript

#24
Instead, why don't we eliminate the need for Apps in a browser to require HTML. Right now, our large scale app has one div inside the . It's just an anchor for our SPA built in React js. We should push for browsers that can launch from a .js file, rather than requiring html. Have a base UI.kit that can even keep css, or use javascript to stylize. I'd like the 'base' UI to be as skeleton and simple as possible. We can keep the style markup, but with javascript first. Similar to what JSX does with React. This would also fix the DOM problem we are currently stuck with. This is a rough, quick typeup, thoughts though?

EDIT: and most importantly, get multi-threaded javascrip in the browser. Running the UI, events, and logic all on separate threads. Many observe patterns would most likely be used.

Re: HTML6 proposal for single-page apps without JavaScript

#26

This is interesting, but like others I think HTML should be kept strictly for templating, and this adds an unnecessary amount of logic. It might be tempting to see this as removing complication, but in actuality it will probably add to it by reducing separation of concerns. I think it would be good for less ambitious projects, but in the end it would cripple the building of more ambitious ones. If we already have Ang…

HTML does not do templating, either.

Re: HTML6 proposal for single-page apps without JavaScript

#27

Single page apps seem like a hack to make browser apps feel like they are closer to native apps. Because most SPAs have a set flow, it seems like we should be able to use prefetching to tell the browser what is most likely to happen next. For example, if you are on a list, then you can tell the browser to prefetch the details. What I feel like is missing from this equation is a nice transition between pages. How nice…

So if you have a list of 100 links you are going to prefetch all 100?

Re: HTML6 proposal for single-page apps without JavaScript

#28

Instead, why don't we eliminate the need for Apps in a browser to require HTML. Right now, our large scale app has one div inside the . It's just an anchor for our SPA built in React js. We should push for browsers that can launch from a .js file, rather than requiring html. Have a base UI.kit that can even keep css, or use javascript to stylize. I'd like the 'base' UI to be as skeleton and simple as possible. We can…

> Instead, why don't we eliminate the need for Apps in a browser to require HTML.

Accessibility.

Re: HTML6 proposal for single-page apps without JavaScript

#29
post #27

Single page apps seem like a hack to make browser apps feel like they are closer to native apps. Because most SPAs have a set flow, it seems like we should be able to use prefetching to tell the browser what is most likely to happen next. For example, if you are on a list, then you can tell the browser to prefetch the details. What I feel like is missing from this equation is a nice transition between pages. How nice…

So if you have a list of 100 links you are going to prefetch all 100?

No, that is not really the use of prefetch. It is for more predictable flows.

Re: HTML6 proposal for single-page apps without JavaScript

#30
I see three problem here, none of which have anything to do with HTML as a markup language.

1. The amount of DOM manipulation required for a relatively advanced single page app is not very efficient, quick or performant.

2. Web apps don't work well without a reasonably up to date javascript engine - users may not even allow Javasacript to be run. This breaks alot of web apps.

3. There isn't an (easy) way to request parts of a resource easily using HTTP.

Luckily these issues have solutions:

1. Invest time in a new successor or radical improvement over the current DOM - think an asynchronous, thread safe API. Fix things that deal with HTML, don't try and make HTML anything more than a markup language.

2. Either make your web apps fallback to HTML + CSS or start convincing people that using Javascript isn't a huge privacy issue. Fallbacks can be easy if you want them to be.

3. I'm sure there are way to request specific parts of a page (indeed, I coded such a way myself in PHP a few years ago), but someone needs to build an awesome abstraction over HTTP to make this easier.

Post reply on HN