Ask HN: If you were to build the web today from scratch how would you design it?
9 comments
One part I could see being done differently is JavaScript. A better, purposefully designed language for the web could be very beneficial.
I think in many cases - not all - people complaining about JavaScript don't really understand it.
JS isn't a best-possible-thing, but a surprisingly good Lisp without parentheses. I think, Crowford's "Good Parts" has good points.
JS isn't a best-possible-thing, but a surprisingly good Lisp without parentheses. I think, Crowford's "Good Parts" has good points.
(not OP) I agree with this. To be fair, I believe there are some design mistakes underlying JS, but even C has its blemishes.
IMHO one of the reasons why people are so negative about JS is that they have in mind older versions. Pre-ECMAScript 2015 JS is really bad; ES6 is a reasonable and modern language, it is in fact my go-to language when I want to write something quick and dirty.
Java is also like this. Java pre-8 is an unusable stinking turd of a language, Java 8 is tolerable, Java 11 is a modern language that I have few complaints about.
Same with C++ pre/post cpp11. I'm sure there are more examples as well.
IMHO one of the reasons why people are so negative about JS is that they have in mind older versions. Pre-ECMAScript 2015 JS is really bad; ES6 is a reasonable and modern language, it is in fact my go-to language when I want to write something quick and dirty.
Java is also like this. Java pre-8 is an unusable stinking turd of a language, Java 8 is tolerable, Java 11 is a modern language that I have few complaints about.
Same with C++ pre/post cpp11. I'm sure there are more examples as well.
People will probably comment with a wishlist of individual improvements over what we have today, but a fundamentally different design that covers all of todays usecases will be hard to fit in this comment field.
I would design it as a Web of Apps rather than the Web of Docs.
Lots of current issues are because it started as a Web of Docs, yet what people wanted was the Web of Apps.
It would also be based on UDP rather than TCP.
There will be no cookies, Local Storage covers it.
Authentication based on public key cryptography.
Search similar to RSS, where each site provides an API feed, not bots scanning content.
And on and on it goes :-)
Lots of current issues are because it started as a Web of Docs, yet what people wanted was the Web of Apps.
It would also be based on UDP rather than TCP.
There will be no cookies, Local Storage covers it.
Authentication based on public key cryptography.
Search similar to RSS, where each site provides an API feed, not bots scanning content.
And on and on it goes :-)
> I would design it as a Web of Apps rather than the Web of Docs.
These are two significantly different use cases. Maybe there are more? Like, apps can be split further into classes?
> Lots of current issues are because it started as a Web of Docs, yet what people wanted was the Web of Apps.
Disagree, lots of people today point out that the grass was greener when we had the Web of Docs, and want that state back.
> It would also be based on UDP rather than TCP.
TCP is just a rather common case - lots of cases want to have guarantees with data. We probably want to be able to use UDP as well, don't we go towards that with WebRTC?
> There will be no cookies, Local Storage covers it.
So it wouldn't work outside of the session? We'll need to keep entering passwords?..
I think some Internet things could be improved as well, not only Web.
These are two significantly different use cases. Maybe there are more? Like, apps can be split further into classes?
> Lots of current issues are because it started as a Web of Docs, yet what people wanted was the Web of Apps.
Disagree, lots of people today point out that the grass was greener when we had the Web of Docs, and want that state back.
> It would also be based on UDP rather than TCP.
TCP is just a rather common case - lots of cases want to have guarantees with data. We probably want to be able to use UDP as well, don't we go towards that with WebRTC?
> There will be no cookies, Local Storage covers it.
So it wouldn't work outside of the session? We'll need to keep entering passwords?..
I think some Internet things could be improved as well, not only Web.
Honestly my main gripe with the web (and also with the Internet in general, to a certain extent) is how centralized it is, but that's an economics/people problem, not a technological one. The overwhelming majority of Internet users don't actually want the internet, they want a portable television, and that's exactly what they got.
I doubt different technological choices would have eventually lead to a significantly different arrangement, except for minor implementation details only nerds like us care about.
I'd bake in micropaynents based on digital currency from the very start.
So in other words I'd invent Bitcoin or eth and make them first class citizens on the web so we have p2p payments for content, and this would then happen before KYC and AML so everyone would be awash in a sea of digital currency and all world be right with the world.
I'd also pass a law in every country that created a Digital World Heritage Fund, making destroying of digital works and sites deemed heritage a crime or offence. Digital preserve for us and the future. And I'd make sure GeoCities was on the Digital Heritage List.
I'd also make search, and a basic news feed based social network first class citizens part of the infrastructure of the internet, free and available to everyone, and supported in the same manner that the network backbone is supported... Or better... I'm not an expert on that part, someone else can nut out the details of how to support it.
In that parallel universe, Zuckerberg would be expelled from Harvard for spinning off Hot or Not into a porn site called Facebook, and trying to blackmail students with sextapes for favors, and Larry would be CS head of dept at Stanford, while Sergei would lose both arms in a wingsuit accident and become a womanizing paralympian. Eric Schmidt would stay at Novell, and Google.com would be owned by a birdwatcher from Nova Scotia with a side hustle in crank conspiracy theories.
YouTube would be the most popular website in the world, where a cat would have its own channel and become the first animal billionaire, then be elected to the US Senate in Delaware, and then removed in a tax scandal.
2001 would never Pop and the founding team at Pets.com would now be there richest people in the world. Jeff Bezos would see no opening for a books retailer, or anything else, and would eventually find his biological father and take over the family bicycle shop and repair business, and would marry a waitress at the local diner who always remembered his order and always flicked him a smile.
Elon and Peter et al would never start X nor PayPal, but instead would move to LA and write scripts and get into Hollywood. Eventually co-directing DCs answer to the MCU and giving the LaRussos a serious run for their endless money.
So in other words I'd invent Bitcoin or eth and make them first class citizens on the web so we have p2p payments for content, and this would then happen before KYC and AML so everyone would be awash in a sea of digital currency and all world be right with the world.
I'd also pass a law in every country that created a Digital World Heritage Fund, making destroying of digital works and sites deemed heritage a crime or offence. Digital preserve for us and the future. And I'd make sure GeoCities was on the Digital Heritage List.
I'd also make search, and a basic news feed based social network first class citizens part of the infrastructure of the internet, free and available to everyone, and supported in the same manner that the network backbone is supported... Or better... I'm not an expert on that part, someone else can nut out the details of how to support it.
In that parallel universe, Zuckerberg would be expelled from Harvard for spinning off Hot or Not into a porn site called Facebook, and trying to blackmail students with sextapes for favors, and Larry would be CS head of dept at Stanford, while Sergei would lose both arms in a wingsuit accident and become a womanizing paralympian. Eric Schmidt would stay at Novell, and Google.com would be owned by a birdwatcher from Nova Scotia with a side hustle in crank conspiracy theories.
YouTube would be the most popular website in the world, where a cat would have its own channel and become the first animal billionaire, then be elected to the US Senate in Delaware, and then removed in a tax scandal.
2001 would never Pop and the founding team at Pets.com would now be there richest people in the world. Jeff Bezos would see no opening for a books retailer, or anything else, and would eventually find his biological father and take over the family bicycle shop and repair business, and would marry a waitress at the local diner who always remembered his order and always flicked him a smile.
Elon and Peter et al would never start X nor PayPal, but instead would move to LA and write scripts and get into Hollywood. Eventually co-directing DCs answer to the MCU and giving the LaRussos a serious run for their endless money.
Not an expert on distributed systems, but I'd want it to be as de-centralized as possible (it is significantly now, but there are choke-points like SSL and DNS authorities). I'd want no government or corporation to be able to control anything about anything on it. It would be like the before time, when Facebook hadn't come along and caused governments and corporations to take interest in controlling it.