4 ms·
Allow me to describe a revolutionary way of creating web applications. I call it "Pages and forms". If you need to display some information, you use an abstrac
by simonw 13y ago
Allow me to describe a revolutionary way of creating web applications. I call it "Pages and forms".
If you need to display some information, you use an abstraction called a "page" - a full HTML document served from a URL. You can generate the HTML using a variety well understood, easily tested server-side frameworks. You can even just serve static HTML saved in a file.
Pages are easy to scale, easy to link to and work on every device, platform and browser released since IE and Netscape 3 back in 1996 (or earlier if you don't need to rely on the Host header).
How about adding interactivity? That's where "forms" come in. Forms allow your application to request information from users and submit it back to your server using a simple and widely understood key/value mechanism.
By combining pages and forms you can build applications that work everywhere, are easy to link to, easy to maintain and can be scaled to handle anything you can throw at them.
- oneeyedpigeon 13y agoAdd a thin-layer of javascript for immediate feedback on certain UI operations, and I'm sold.
- tonyedgecombe 13y agoIt won't catch on :)
- Rusky 13y agoStatic web apps are excellent for things like webmail, Google Docs, etc. that aren't going to be crawled. It's simpler there, and is probably how things should work in a hypothetical non-web-based but still deployed-web-style app ecosystem. For a blog, or a forum system, or twitter, or anything that should be crawled and linked to and shared, it doesn't really make sense, and "pages and forms" makes much more sense.
- jfaucett 13y agoI see your point but sorry, its nonsense when talking about "webapps" - as opposed to anything largely text based and with very limited user interaction. You are going to have to rerender the page for every single user action. The feedback the user gets is going to be ridicously slow for marginally complicated apps, creepingly slow on low-bandwith devices. Just deleting an item in a paginated list will require posting data while maintaining the query parameters in the url, running a possibly very complex query on the server again, recalculating and rerendering the page and then shoving that data all back to the user via expensive TCP cycles - huge waste. A "webapp" on the otherhand makes a post to the server gets a 204, and on the client side simply removes the corresponding dom element. As an example, think about implementing MS Paint and the corresponding user experience - using what you're talking about.
- derengel 13y agoI agree with you but isn't paint program a bit extreme as an example? surely much less interactive webapps can also benefit lots from programming all the logic/UI on the client? (newbie)
- simonw 13y agoI agree that you'd be nuts to build an interactive drawing program like this... But the vast majority of what people are calling "web apps" today aren't anything like a drawing program. I'm also personally a big fan of adding a layer if JavaScript to improve interactivity, but the "static apps" approach advocated in the OP goes way too far for most apps in my opinion.