(Also, after seeing the below 350-line function that's part of a 3113-line file, I now know that whenever I'm yelling at CSS layout behaving weirdly, there's someone with a much, much more frustrating job.)
EDIT: for anyone who doesn't know, https://servo.org/ is Mozilla's ambitious project to rewrite their browser from scratch with concurrency thought in from the beginning, supported by Rust's unique approach to safe concurrency. Parts of it have already made it into Firefox: https://bholley.net/blog/2017/stylo.html
Browser authors are on the receiving end of over 20 years of standards all written by people who were not, personally, the ones implementing them, plus a healthy dollop of "code that worked in this one browser once and become a de facto standard", for which the way tables format themselves in all their myriad ways comes to mind, based around whatever was convenient in already-crufty codebases now long dead.
I don't spend a lot of time wondering why my browser is so slow; I often find myself wondering how it manages to be so fast. The spec for a browser is insane. I definitely believe that a future of browsers will be a combination of web assembly and a much more raw rendering layer that will offer access to font rendering and the OpenGL primitives, and a non-trivial number of the biggest websites will eventually implement their own renderers. I say "a" future because the current web rendering system will be around to the end of my prognostication powers. But I suspect this bypassing of the "legacy" renderer is also ultimately inevitable. Give it about 5 years or so.
At my job, our group recently refactored a file from over 30000 lines down to 17000. I've also seen, on multiple occasions, single methods in Smalltalk applications that exceeded 32KB and therefore broke the compiler! (The egregious sins of Smalltalk shops were weirdly parallel. The egregious sins of Smalltalk vendors were also weirdly parallel, come to think of it.)
Frankly what went wrong was that print media designers got involved and used flash and JS to turn static text into virtual pamphlets etc.
Let put a end to the madness, and say "after 2020, not more in the old apis" and do a clean standard. Then take advantage of the fact html/js have tags that could declare versions, and when a old page show, use the old rendered, and when a new, use the clean one.
By then, most PC/mobile devices are powerfull enough to have 2 renders alive and the transition will be fast for more big/popular sites.
There are multiple versions of ECMAScript, analogous to whether your compiler supports C++11/14/17/etc. It doesn't make sense to say "let's all use ES8" because ES8 is back-compatible (I think). It's up to the browser to decide what to support, and you have the same issues in C++ where some compilers don't fully support feature X.
Then, which APIs do you deprecate? How do you define "old"? Anything prior to stable is a good rule of thumb, but since JS can be loaded locally, people will use whatever they downloaded and that they know works. Some people advise not to use auto-updating CDNs precisely because a patch might break your page. And remember it's mostly down to the API developers to ensure compatibility across major browsers, not vice versa.
There's nothing wrong with vanilla JS. Really we just need to get people to be less excited about using frameworks for tiny projects that don't require them. Or you have problems like e.g. some text transition that requires loading every single version of the typeface.
Eventually, you increase ad infinitum the tech debt, or restart.
I think the cost of the whole web stack is high enough not only for the browser makers but EVERYONE ELSE. Is multiply JS (n-versions) + CSS(n-versions) + HTML(n-versions) * N Browser * N OS.
Now, what other rational option can be offered... push forward and keep doing the same and increase the tech debt? Not exist a way to refactor this?
Understatement of the century for 500.
Web developers - want a clean, extensible, sane system to code against
Major consultancies (e.g. IBM) - want lock-in, wide and cheap talent pool, and minimal changes (unless it's an issue they have)
Browsers - want to render whatever they see fastest and securely
Content developers and end customers - never want to have to update their site that they bought in 1995
So I guess the question is not if its ok for chrome to break the web for half the world its if its ok for chrome to impose this cost on site owners on behalf of users for the benefit of users.
Incidentally while there may be a lot of tiny sites that don't use https aprox 3/4 of page loads are already over https. Making myrandomhomepageaboutcats.com switch to https seems a reasonable cost for making the rest of the web more secure.
Comparison with Flash et al. is not accurate anymore, since these ran in an unprotected environment. Also, they were cumbersome install whereas WASM apps don't need installation (but can live in a cache if desired, and could even be shared among websites).
Fundamentally the problem is the conflict between the browser as an 'app' platform and the browser as a document viewer. Put simply, would you rather your user interface be 1) a magnificent piece of software with thousands of man-years put into it, debugged over decades, where every use case has been meticulously considered, or 2) a shitty script written by an overworked web developer?
As a anadotal. We can already fo to websites that run vms and emulate old operating systems. I dont this it is far fetched to run a web browser in a web browser.
It sucks but this is the way we're heading. I'm not sure web devs will even be writing HTML in 5 years beyond adding a canvas tag.
In fact, the approach would be more general, since a lot of text is already embedded in images on a lot of websites (think also about ads).
Not to mention that there's no such thing as "Easily run OCR", considering how many weird fonts there are, and that they could be rendered in such small size as to make it difficult even for humans to tell them apart.
The simplest example: how do you indicate a graphic or piece of text is a button or link? How do I set the alternate text if it’s a graphical button.
Besides, nobody says we can't have a protocol for some additional accessibility information.
1. No-one uses it
2. There is only 1 implementation, and it is never updated
And then we wonder where all the software bloat comes from.
So why doesn't everyone roll their own? Some issues:
- footprint - that whole runtime has to come across the wire just to render "hello world"
- text rendering [this happens to be the thing the document-focused Web really excels at]
- text semantics [SEO]
- gigantic implementation effort [custom engines RARELY make sense even for the demands/budgets/returns of AAA games; how many websites justify this kind of investment?]
I don't think that's true. At least, all the browser standardization processes I've been involved in included several people who would be responsible for actual implementation.
In my ideal world, browsers are spec'd in a functional language, and optimized mechanically (perhaps based on ad-hoc human guidelines).
It will be interesting to see if they keep merging in changes from the head of the open source browser or if they continue to diverge over time.
Secure job though, with predictable repeatable work.
The Chinese governmental structure is very much communist. The ideals in the propaganda are communist. The goverment has strong control of their citizens, controlling how many children they can have, which city they can live in, etc.
They've kept all their pretenses of communism.
We aren't a pure capitalist society, or a pure republic, or democracy. We still use those words to describe ourselves. It's important that we do use those words to describe ourselves. The phrase 'all men are created equal' in the declaration of independence aided the abolitionist argument, even if at no point did the goverment treat all men as equal.
The ideals of communism still have an impact on China's goverment, culture and even economy. Just because they fall short of a perfect communist society doesn't mean they are not communist.
> The goverment has strong control of their citizens, controlling how many children they can have, which city they can live in, etc.
is specifically talking about the totalitarian nature of their government.
Or in other words, all private capital ownership and private business ownership is illegal.
Lots of people own businesses in China. Therefore, by definition, it isn't communist.
I've always thought communism was just an unachievable ideal. With socialism as the best case implementation of it, and totalitarianism as the worst case.
Kind of like how "free market" is an ideal, but capitalism is generally the implementation.
In those two societies, almost all businesses we're owned by the government, so I think that counts.
Modern day China doesn't count as there are tons of billion dollar businesses owned by shareholders and private parties.
Actually not "all communists are totalitarian" either.
as for children you are allowed to have two which nobody really wants anyway and they plan to introduce three or no limit at all
i lived in China for years and now appreciate communist EU more
Newsflash: workers never owned the means of production in any communist state. They were told they would, but they were subjected to compulsory work to cater to the communist regime's elite goals while owning nothing at all.
That sort of bait and switch is pretty much the hallmark of every single communist regime since the very beginning.
That said, I don't really care that dictatorships after dictatorships called themselves socialist and communist, people's this and that, they - as good populists always do - subverted the people and their ideas.
Just as North Korea is a "democratic" "republic".
Mistake not this nitpicking for defense of communism. I don't think it makes any economic sense to strip away savings and investment and everything else connected to those for compulsory ownership of your workplace.
So yes, bait and switch is what populism is. And it worked and continues to work wonderfully independent of political leaning/orientation.
I'd be surprised if you found the red/yellow/green logo image in chromium
That's a disingenuous phrasing, though.
It was set up in a dumb way, but people also grossly misreported. The extension was "enabled" by default but did exactly nothing except shut itself down. The behavior was all disabled by default.
Of course it was. It shilled a TV show.
Hmmm... I seem to have missed out on some super-Venezuela levels of hyperinflation happening to the yuan at some point here. You think that'd be the real news.
If indeed the yuan had collapsed by a factor of one million since I last checked the news last night, I don't think even the infinite canvas of online news would have a lot of room to be discussing browser plagiarism amidst the torrent of commentary about China's currency collapse and the imminent and/or occurring collapse of the international economy.
If there's anybody with some yuan on hand, I'm willing to offer you a heck of a deal. I'll happily give you $72 for your 250 million yuan. I'm taking a bath on this deal, but I like HN that much and I'm willing to cut you a favor.
Similar to when people use 2-800 instead of 200-800: Best to just be clear.
I really don't know currency conversions and maybe it is $360 million ....
I pointed out that when Netscape decided to rewrite their browser, with all the knowledge they had of how browsers work, they spent three years doing it, and that was a decade and a half previously when the web was orders of magnitude more simple.
I sometimes wonder how out of context he was. Or I was? What did he think a browser was? Were we speaking at massive cross-purposes? Did he mean we should grab some other web engine and find a way to use that? Even so, a half-day to get something going? And just what introductory programming textbooks was he reading?
Where was I going with this? Somewhere along the lines of how "write a browser" clearly can mean massively different things to different people, or maybe that there can be an enormous gulf of context and understanding there somewhere. To this day, I still don't know. Never will.
Getting a first cut of really basic HTML rendering--essentially saying, here's a string that's X color and Y font, display it--is probably doable in a day if you have robust implementations of everything else. I have to imagine your director thought that doing HTML rendering was "all" you'd have to do. Of course, what makes building browsers especially hard is there is very tight integration between all of these different components, so that you have to maintain all of these pieces.
In the old days of Chrome you'd occasionally see WebKit engineers griping about how Chrome was taking all the credit for just repackaging WebKit. I remember wondering about this at some point and noticing the code was roughly 50-50 Chrome/WebKit in terms of size (which is a fraught measurement always but hopefully gives you the idea). To be sure the HTML-rendering part of a browser is a central piece of it, but the Chrome part included stuff like v8, the Windows port of WebKit, the network stack, the multiprocess architecture, all the browser widgetry like tabs, bookmarks, and the fancy URL bar, and so on. So I guess even for people who are close to this it's hard to say what making a browser entails.
Here's an image from the announcement:
Classic - he mentions not wanting to rip off state funds and government agencies multiple times. Thats exactly what he did though ;) I hope this isn't the last anyone ever hears from Chen Benfeng - "The special expert of the National Thousand Talents Program”.
I'm shocked with that much funding, this startup would choose to either or both a) plagiarize, b) falsely advertise, and they didn't even do it well. I'd say the effort is worth $36 without the million.
Both of these actions (plagiarism, fraud) have ethical and legal implications, but it sounds like they are getting away with this by admitting to the public what they did.. That makes me think the investors were already aware/supportive of the whole stunt.
Is this what the startup scene is like in China? I certainly hope not.. but still, it will take heck a lot more innovation from this company for people to ever trust them again.
I wouldn't chalk this particular instance up to anything more than loose capital ending up in fraudster hands, as occasionally happens when it's sloshing around to such a degree as it is these days.
Meaning they send your browsing data to Chinese government agencies?
I want that too.
Just if someone else need their national browser too - I am here with my Sciter (https://sciter.com) - it is an independent implementation of HTML/CSS and universal Web browser can be made from it with 6-9 months ETA.
Umm, Webkit spun out of Safari, so that would make Chrome the "clone" of Safari.
Which is rather your point. Chrome has made a lot of changes to Webkit over the years, and these days appears to be putting more effort into it than Apple is.
webkit/safari was spun off of KHTML/Konqueror, so would that make Safari a "clone" of Konqueror
Implying that WebKit somehow stalled because Google forked it into Blink is silly. Apple and Google are both investing heavily in their browsers, just with different priorities. Doesn't take more than just looking at the WebKit blog to see that.
I use Safari by preference and wish Apple would push harder, but perhaps my attitude is a little unfair.
Culture is bigger than any individual.
IP & Copyright are not part of Chinese history or culture and were largely impositions from
The west within the last 50 years.
Something like 90% of all business software running in China is stolen.
Additionally, Marxist ideas of collective ownership have left their mark.
It's more like someone wanna wash their cash..
Besides this cliche was said for the US (back when it copied European inventions in the 18th and 19th century to bootstrap its industry) and Japan in the 60s and 70s (which started by copying western products).
Funny how those two places turned out...
They clearly sold it as their own rendering engine, not just a UI shell. Although I guess due to vague wording it wouldn't necessarily preclude being a fork of Blink.
(I say this as a fan of KDE, and a user of Konq back in the KDE2x/Mandriva days.)
There's plenty wrong with taking money on the promise that you're developing a browser from scratch, then doing the above.
Apple Safari ‘found to be’ Konqueror...
Also: copy 80% of a successful product and innovate/improve another (core) 20% is a very smart business approach.
Kudos an good luck to the Chinese for the attempt to disrupt monopoly in this space.