TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: How you would redesign a web browser?

16 点作者 skarras超过 3 年前
HTML is a markup language for documents and CSS and JavaScript are here just to give some help.<p>But now days people are using HTML&#x2F;CSS&#x2F;JavaScript for shipping complex apps not pages. And not only that but people build asm.js in order to ship even more complex things in a browser which is not a bad thing but it feels like having a hammer and hitting stuff.<p>Lets assume that we will allow all this technology to die.<p>How you would redesign a system that allows people to access complicated apps from a web browser?<p>Which parts you would keep and which parts you would through away?

15 条评论

robgibbons超过 3 年前
Not to sidetrack your topic of discussion, which I think is interesting, but I think it&#x27;s an unfortunate misconception when people try to cast browsers as being intended to merely display documents. Hypermedia in general is a very old concept, dating back to the 60s, and it was never intended to be limited to merely documents. Audio&#x2F;visual and interactive applications were inherent in the design of some of the earliest hypermedia systems which informed the design of the web.<p>The first websites on the WWW may have been just documents, mainly showing off basic hypertext concepts, but the basic elements for interactive applications were there. The web was just one system amongst a category of other examples of hypermedia which included more interactive and visual applications. NLS and Hypercard being great examples.<p>Not to say browsers couldn&#x27;t be improved, or that new systems shouldn&#x27;t strive to be better. But I disagree with the fundamental assertion that the web, and browsers, were ever intended to only display documents.
评论 #30343819 未加载
kevincox超过 3 年前
I would separate the app-rendering and document-rendering, but in a composable way. Document-rendering would be much like reader-mode today where the browser applies a lot of styles to make the text beautiful and readable based on the user&#x27;s preferences. App-rendering would have incredibly consistent default styles (such as no margins, no padding, no underline on links). Basically I feel that browser default styles are ugly because they are afraid to break the &quot;app-rending&quot;. I think separating these would allow the browser to make document-rendering much nice. I wrote a blog post with more detail. <a href="https:&#x2F;&#x2F;kevincox.ca&#x2F;2021&#x2F;07&#x2F;14&#x2F;chrome-and-content-modes-in-html&#x2F;" rel="nofollow">https:&#x2F;&#x2F;kevincox.ca&#x2F;2021&#x2F;07&#x2F;14&#x2F;chrome-and-content-modes-in-h...</a><p>On the other side can a major browser fix keyboard shortcuts. I want 1. User controllable keyboard shortcuts. (Ideally with some sort of scripting or macro system) 2. Don&#x27;t allow websites to override important browser shortcuts. Why can&#x27;t I open my history when looking at a Google Doc?!
emptyparadise超过 3 年前
Split the browser into two separate platforms, for apps and for interactive documents.<p>The app platform should focus on covering app scenarios, but with better privacy protection mechanisms.<p>The document platform should focus on hypertext and not feature scripting, but there should be features built in for handling live refreshing feeds of content.<p>Of course nobody would ever want to use the document platform since you won&#x27;t be able to control the user. But it&#x27;d be nice.
评论 #30346335 未加载
sudiptadeb超过 3 年前
1. Remove legacy HTML support. HTML should become a format agnostic DOM. Without any scope of inline style or scripting. So even a markdown document could possibly be natively rendered albeit with limited element support<p>2. Styling should be done exclusively out of band. CSS is a great tool, but a massive decluttering is required. Native can also be a supported styling option.<p>3. Same out of band scripting. JS is fine. Support can become language agnostic. wasm and others will come under this.<p>In conclusion the browser should become a decoupled selectable network of Markup, Styling and Scrpting. So when the developer wants they can style the components with native android widgets or canvas and when they want they can write the business logic in Swift or Rust or Dart<p>I see browser as a framework provider for native apps with prebaked features like assessibility, multiple input devices, sandboxing, etc
Const-me超过 3 年前
Replace JavaScript with .NET: it delivers byte code not source code, the byte code was specifically designed to allow JIT into efficient machine code with minimal overhead.<p>Replace HTTP and HTML with binary equivalents. A human-readable representation is nice when debugging things but binary equivalents are way faster, both throughput (handling strings is slow in general, too many branch mispredictions) and latency (to save bandwidth, text is typically combined with gzip or similar, they have internal buffers, they cause latency).<p>Implement data templating and data binding at HTML level. These things are essential for apps.<p>Keep the CSS, it&#x27;s mostly fine.<p>Replace SVG with something binary, scriptless, and optimized for viewing only. Here&#x27;s an example <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=29629792" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=29629792</a>
eatonphil超过 3 年前
More pluggable textareas. I&#x27;d like to be able to use more emacs controls on all systems and even Mac only supports the most basic ones. I can&#x27;t do emacs text highlighting and so on.<p>My point isn&#x27;t just about emacs but that there are powerful text editors like emacs with powerful keyboard shortcuts and I&#x27;d like to be able to have more of that in the browser while I&#x27;m editing emails and blog posts and whatnot.<p>Yes there&#x27;s that one browser plugin that allows you to open an emacs window and it sends the result to the textarea but I don&#x27;t consider that a good alternative at all.
dusted超过 3 年前
It would come with options for the user to select font&#x2F;size&#x2F;colors for various well-defined elements like head-lines, new links, previously visit links, external links. It would be easy and convenient for the user to configure their preferred formatting of the text (width, line break behaviour, justification).<p>It would not allow client-side execution of any kind, it would not allow any kind of styling of the content, only describe what the content is, not how it should be presented.
aristofun超过 3 年前
Use dart instead of js - minor improvement.<p>Make the tabs go on the side, not on top&#x2F;bottom - killer feature that no genious product managers out there managed to realize.
gxt超过 3 年前
Security is lacking in my opinion, this is a question I asked on se last year about missing browser security features. <a href="https:&#x2F;&#x2F;security.stackexchange.com&#x2F;questions&#x2F;254923&#x2F;is-it-possible-to-protect-browser-credentials-from-malicious-processes" rel="nofollow">https:&#x2F;&#x2F;security.stackexchange.com&#x2F;questions&#x2F;254923&#x2F;is-it-po...</a>
m348e912超过 3 年前
I would do a better job with two things: Keep better state of unused tabs without sucking up a ton of memory. Allow users to click &quot;back&quot; without reloading the page or jumping me to a different section of the page where the link that was just clicked on is no where to be found.
danielscrubs超过 3 年前
Gut feeling is that there are a lot of overlapping features in CSS. With Flexbox &amp; CSS Grid can some things be deprecated?<p>Also I&#x27;d try to unify the syntax for HTML&#x2F;CSS&#x2F;JS to be easier for beginners.<p>Overall, make it smaller so that we can have more competition in the browser engine space.
sparker72678超过 3 年前
No data sent to 3rd party at request time. No headers, referrers, nothing.<p>If I could figure out a way, no JavaScript, either.
lanecwagner超过 3 年前
I think we should treat web &quot;sites&quot; and web &quot;apps&quot; as two distinct things... Because they are two distinct things.
评论 #30347458 未加载
themodelplumber超过 3 年前
I think I&#x27;d like to see a node-based &quot;communications design &amp; rendering environment&quot; where you could use an HTML node if you want, use JS or CSS or other stuff if you want. Or you could drop in some text into a plaintext node and there&#x27;s your output.<p>I&#x27;d expect that you could also create nodes of nodes, in other words distribute a bunch of nodes as a single node. Here&#x27;s a &quot;typical website&quot; node, here&#x27;s an &quot;asm.js person&quot; node. And here&#x27;s a &quot;discussion site&quot; node.<p>But then, you could connect those nodes together, or to other things, and make nodes of _those_. Let&#x27;s say you connect a &quot;podcast bot&quot; node to your &quot;discussion site&quot; and it defines a new endpoint that hosts a pretty good podcast out of what it finds on the discussion site.<p>The concept would focus more on what&#x27;s going where, in what form, and try to abstract out the connection types a bit more, similar to how a networking stack already has made a good start at being invisible. If my connection between HTML and JS can be less of &quot;which CDN do I use, sigh, here&#x27;s another link element to maintain over time&quot; and more of like, a line or visual connector, that&#x27;s the kind of invisibility that would be really helpful.<p>The browser could then be more of a generic design &amp; rendering platform aimed more squarely at users--ideally even giving users&#x2F;visitors node editing access. Imagine if &quot;View Source&quot; looked more like a design environment, with full code access for those who want it. But in the meantime, start arranging and editing, and see what happens.<p>That could be pretty amazing for opening the web up again, and providing really exceptional accessibility. To gauge how well a browser can compete, we could ask how open the experience is, what node-level freedoms it gives to users, etc. Or we could ask what level it provides--at a basic level maybe a browser only renders text and HTML nodes, but it&#x27;s easily expanded by specification. Or maybe by specification it shows you the full node network, highlighting only the parts it can work with.<p>It would also ask more of a &quot;how much tech does a publisher really need&quot; question which I think is important given the lumbering stacks many publishers are forced to maintain these days. For example, last year I had to let a science fiction author know that Laravel was displaying their DB credentials for about 500ms until it was covered by their article div. This isn&#x27;t anybody&#x27;s fault necessarily, but we are talking about a website with text, links, images.<p>Just some thoughts though. I&#x27;m sure it&#x27;s also broken in some ways but it could be pretty cool...good q.<p>P.S. this is thinking in visual terms, but I&#x27;d expect full &amp; logical accessibility for screen readers, etc.
cookiengineer超过 3 年前
I think that in order to increase privacy and - more importantly - reduce the attack surface of a Web Browser more efficiently, there will have to be two modes of web browsing.<p>Regular browsing - in my opinion - should default to privacy and security first, whereas trust to web apps should be granted on a per-domain basis. This is basically what I&#x27;m doing in a crappy manner in Chromium and Firefox, where I have all my Browser Extensions in regular browsing mode with uBlock Origin, Cookie Autodelete and whatnot... and where I use Incognito Mode to use Web Apps.<p>Additionally, I believe that a Web Browser that&#x27;s decentralized has an almost infinite amount of advantages when it comes to bypassing censorship, increasing trust and the ledging aspect of (temporary) online resources.<p>My idea of building a sane architecture of a Web Browser is that the Browser itself is actually a locally running peer-to-peer web scraper service, and the &quot;frontend or GUI&quot; is a bundled webview that&#x27;s pointing to localhost:someport. Web Apps can then be used by spawning a new webview instance that&#x27;s sandboxed with its profile in a temporary folder, so it cannot infect&#x2F;spread across the regular profile folder that&#x27;s being used for the &quot;regular private browsing&quot; mode.<p>This architecture allows all kinds of benefits, as everything can be filtered, cleaned, verified (, and shared with other peers) at the network level before it reaches the webview - whereas Browser Extensions currently cannot filter any HTTP responses because there&#x27;s no API for that.<p>AdBlockers currently are based on a disallow-list based concept, which means the advantage is always on the advertising side, and by default nothing is filtered; and scammers&#x2F;blackhats have always the advantage. Once you add it to a filter list, lots of people&#x27;s machines have been compromised already. But what if AdBlockers change instead to an allow-list based concept - meaning that the Browser maintains a list of resources that are allowed to load per-domain, and the default being just text and images?<p>If you want to take a look at where it&#x27;s at right now [1] [2], my Browser is open source; and I hope to fund development via a access fees for a peer-to-peer &quot;Knowledge Tracker&quot; that allows to share automations for the web with other peers, aka macros, reader-mode like extraction beacons, and other awesome treats (p2p search and recommendations are basically included in this concept).<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;tholian-network&#x2F;stealth" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;tholian-network&#x2F;stealth</a><p>[2] <a href="https:&#x2F;&#x2F;github.com&#x2F;tholian-network&#x2F;retrokit" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;tholian-network&#x2F;retrokit</a>