-
2 votes
-
Ladybird chooses Swift as its successor language to C++
I've copied the full tweet below (it's from August, I missed this news somehow): We've been evaluating a number of C++ successor languages for @ladybirdbrowser , and the one best suited to our...
I've copied the full tweet below (it's from August, I missed this news somehow):
We've been evaluating a number of C++ successor languages for @ladybirdbrowser , and the one best suited to our needs appears to be @SwiftLang 🪶
Over the last few months, I've asked a bunch of folks to pick some little part of our project and try rewriting it in the different languages we were evaluating. The feedback was very clear: everyone preferred Swift!
Why do we like Swift?
First off, Swift has both memory & data race safety (as of v6). It's also a modern language with solid ergonomics.
Something that matters to us a lot is OO. Web specs & browser internals tend to be highly object-oriented, and life is easier when you can model specs closely in your code. Swift has first-class OO support, in many ways even nicer than C++.
The Swift team is also investing heavily in C++ interop, which means there's a real path to incremental adoption, not just gigantic rewrites.
Strong ties to Apple?
Swift has historically been strongly tied to Apple and their platforms, but in the last year, there's been a push for "swiftlang" to become more independent. (It's now in a separate GitHub org, no longer in "apple", for example).
Support for non-Apple platforms is also improving, as is the support for other, LSP-based development environments.
What happens next?
We aren't able to start using it just yet, as the current release of Swift ships with a version of Clang that's too old to grok our existing C++ codebase. But when Swift 6 comes out of beta this fall, we will begin using it!
No language is perfect, and there are a lot of things here that we don't know yet. I'm not aware of anyone doing browser engine stuff in Swift before, so we'll probably end up with feedback for the Swift team as well.
I'm super excited about this! We must steer Ladybird towards memory safety, and the first step is selecting a successor language that we can begin adopting very soon. 🤓🐞
Nitter link:
https://nitter.poast.org/awesomekling/status/1822236888188498031
Original post:
https://x.com/awesomekling/status/1822236888188498031
Some of Kling's replies in that thread are also pretty interesting:
My general thoughts on Rust:
- Excellent for short-lived programs that transform input A to output B
- Clunky for long-lived programs that maintain large complex object graphs
- Really impressive ecosystem
- Toxic communityIn the end it came down to Swift vs Rust, and Swift is strictly better in OO support and C++ interop.
The September monthly report for Ladybird released the day after I posted this. It provides basically the same information:
This Month in Ladybird September 2024
The section about Swift:
Successor language search progress
Over the past year, our core contributors have been exploring potential safe languages to complement or succeed C++. We evaluated several options, including Rust, Swift, Fil-C, and others. While some languages offered compelling features, many fell short in either C++ interoperability or providing the level of memory safety we needed.
After extensive testing and discussion, Swift emerged as the top choice among our core developers, thanks to the new Swift 6 interoperability features and its growing cross-platform support. As a result, we’ve decided to adopt Swift as our C++ successor language.
That said, this will be an incremental shift. The existing C++ codebase is deeply embedded in the project, and a complete rewrite would be impractical. Instead, we’ll be gradually introducing new components in Swift, carefully integrating them with our existing C++ code over time. Look forward to a dedicated blog post on the topic soon.
32 votes -
Relative installed shady browser extension
[Possibly solved, please look at comments] Hey, so recently a family member accidentally downloaded a shady browser extension called: "Easy Print" on Firefox. 30k downloads, no ratings, weird...
[Possibly solved, please look at comments]
Hey,
so recently a family member accidentally downloaded a shady browser extension called: "Easy Print" on Firefox. 30k downloads, no ratings, weird "offical" website and installed accidentally trying to buy tickets. I assume it showed something along the lines of: "Buy ticket now" and they just clicked on it (being overall inexperieced with security). Only extension installed was uBlock until then.
I won't post a link just in case, but you can easily find it by googling: "Easy Print Firefox" or "Easy Print App" for their website.
What makes this weirder is that they change the default search engine to Yahoo, which for me was always a red flag for a hijacked browser.
I uninstalled it, but am concerned that they installed something like a keylogger along with it.
Can anyone help me what this is and, especially, how I can properly teach them the basics of internet safety? Not the first time their PC/browser was filled with unwanted stuff...
Thank you and best regards!
15 votes -
BCD Watch automatically collects and makes available information about updates to Browser Compatibility Data
3 votes -
Firefox will consider a Rust implementation of JPEG-XL
21 votes -
I'm forking Ladybird and stepping down as SerenityOS BDFL
15 votes -
exaequOS: A new platform for convivial computation
9 votes -
Arc Browser has started Beta testing on Windows
26 votes -
The weirdest bug I've seen yet
26 votes -
This month in Servo: better floats, :has(), color-mix(), and more!
8 votes -
Letting users block injected third-party DLLs in Firefox
12 votes -
Let's build a Chrome extension that steals everything
10 votes -
Two types of privacy
6 votes -
The SerenityOS browser now passes the Acid3 test
@Andreas Kling: The SerenityOS Browser now passes the Acid3 test! 🥳🐞🌍AFAIK we're the first new open source browser to reach this milestone since the test originally came out.This has been a team effort over the last couple of weeks, and I'm so proud of everyone who contributed! 🤓❤️ pic.twitter.com/Vw8GkHWSaj
8 votes -
Microsoft unveils 'Super Duper Secure Mode' in latest version of Edge
6 votes -
Cloudflare's inaccessible browser contradicts the company's mission
11 votes -
Oildrop - A self-auditable userscript manager
13 votes -
[Google IO 2021] A high-level overview of how Excalidraw works and the browser APIs it uses
8 votes -
Anyone using a lightweight browser with Linux?
I've got a crappy Chromebook running GalliumOS (Xubuntu) and Chromium is slow as molasses. I tried a few other browsers like Otter and Falkon. They're alright for most sites -- not Tildes, but...
I've got a crappy Chromebook running GalliumOS (Xubuntu) and Chromium is slow as molasses. I tried a few other browsers like Otter and Falkon. They're alright for most sites -- not Tildes, but this seems consistent with QT5 browsers.
Anyway, outside of text browsers, anybody have any light weight browser suggestions?
14 votes -
Is Firefox still a good (enough) browser for privacy?
Someone posted this on the privacy subreddit. I also ended up finding this and this after doing a bit of searching. As someone who isn’t in the CS/IT spheres (chemical engineering is my...
Someone posted this on the privacy subreddit. I also ended up finding this and this after doing a bit of searching. As someone who isn’t in the CS/IT spheres (chemical engineering is my background), Firefox has been my go-to browser for awhile, although I’m being made aware of the flaws of Firefox (most of which go over my head) and behavior of Mozilla. What can be done to fix this, especially considering that Firefox is the only FOSS browser with a significant user base?
22 votes -
How and why to use Lynx – the faster web browser
11 votes -
Chrome will soon have its own dedicated certificate root store
8 votes -
A grim outlook on the future of browser add-ons
15 votes -
chardetng: A More Compact Character Encoding Detector for the Legacy Web
4 votes -
Min: a minimalist web browser
20 votes -
Explanation of how a one-line change in the Windows 10 kernel enabled a sandbox escape in Chrome/Edge/Firefox
6 votes -
The reckless, infinite scope of web browsers
17 votes -
Google Chrome: Behind the Open Source Browser Project (2008)
6 votes -
Firefox UI is now built with Web Components
21 votes -
Unearthed Arcana: `edbrowse`
I recently happened to mention edbrowse in a throwaway comment, and @ainar-g expressed some interest in it. I took my sweet time, but I finally managed to assemble a short(ish) write-up on it, and...
I recently happened to mention
edbrowse
in a throwaway comment, and @ainar-g expressed some interest in it. I took my sweet time, but I finally managed to assemble a short(ish) write-up on it, and my sleep-addled mind is thinking that this topic - niche, weird tools - could just become recurrent.
Terminal brosers, such as
lynx
,w3m
andelinks
, while still used and under more-or-less active development, are very niche tools.edbrowse
fills a niche within that niche, as it's meant for use by non-sighted people, and thus provides an interface even more bare-bones and arcane than the usual TUI/curses apps that share its space.As per the name,
edbrowse
's interface is heavily inspired byed
's, the standard text editor:edbrowse
, in fact, is not just a web browser, but it combines together a browser, a text editor, a mail client, and - for some reason - a database client. All of these functions are mostly controlled via one-letter commands and, as is tradition, only displaying a single?
on error*.edbrowse
is also unique amongst the terminal browsers because of its support for JavaScript and the DOM. The text it spits out is meant for Braille displays and screen readers, so it lacks niceties like color or aligned tables, but if you were to browse toreddit.com
with it, you would see a perhaps ASCII-art Snoo fill the screen†."Browsing reddit? How‽," you might ask. "How am I supposed to get this thing to stop questioning me? All those
?
are filling me with existential dread, I have no idea what to do!"While it's all there in the manual (but not in the manpages, for some reason), reading through 30k words of text can be a bit of a slog. They do provide a cheatsheet, though, even if it's a bit messy.
So, how do you use
edbrowse
? If you already know howed
works, most commands (especially "movement", search and listing commands) will work as expected - it is also an editor, after all - butedbrowse
adds another handful of them.The most important of them is, perhaps,
b
rowse. It will makeedbrowse
put in an HTTP request, grab the response (if any), and then render it. It will print out the length, in bytes, of the response and of the rendered text, and stop there.$ edbrowse edbrowse ready b https://tildes.net 119201 20083
To actually peruse the page you can use any of the
ed
listing commands (p
rint,l
ist, andn
umber), or thez
command.z
works much likep
, but it prints a number of lines (normally 24) while "remembering" your position within the page.0z10 {Tildes} {Log in} <>Sidebar * {Activity} * {Votes} * {Comments} * {New} * {All activity}
Links are indicated by curly brackets, while form elements (both input elements and buttons) are wrapped in angle brackets. You can follow a link by jumping to the line containing it and issuing a
g
o command (usingg2
to follow the second link on that line,g3
for the third,g$
for the last), but, in normal use, you should probably just search for the link text./{Log in}/g 5886 923 0z10 {Tildes} <>Sidebar Log in Username <> Password <> <-> Keep me logged in <Go>Log in
The same thing goes for form elements, but the command to use, here, is
i
(fori
nteract).i
has actually four different subcommands:i[N]=
, to set the value of a text field,ipass[N]
to prompt for the value of a password field,i[N]*
to press a button‡, andi[N]?
to askedbrowse
what that damned element is supposed to be./Username/ i=mftrhu /Password/ ipass hunter12 /<Go>/i* submitting form 124579 20049
You can jump back to the previous page with
^
, and refresh the current page withrf
.Of course,
edbrowse
can do much more - can be configured to do much more, via.ebrc
, as it possessed (very) rudimentary programming facilities. It can edit its own configuration file, and reload it withconfig
, so - rejoice. You won't ever need to leave it.And, after seeing just how aesthetically pleasing its configuration language can be, I'm confident that you won't ever want to leave it.
# Switch to a new editing session e2 no file e ~/.ebrc # Show the last lines of the configuration file $100,113n 100 function+google { 101 b http://www.google.com 102 /<>/ i=~0 103 /</ i1* 104 /^About/+2 105 } 106 function+ddg { 107 b https://duckduckgo.com 108 /<>/ i=~0 109 i2* 110 /<Go secure>/+1 111 /<Go secure>/+2 112 z24 113 }
As I said earlier, while
edbrowse
does possess some programming facilities, they are very rudimentary. Functions are nothing more than sequences ofedbrowse
commands with some flow control constructs: they can do everything an user could do, which means that they are often convoluted and overly terse.The
ddg
function, for example (which is invoked via<ddg [PARAMS]
), firstb
rowses to duckduckgo.com. The DuckDuckGo home page, as rendered byedbrowse
, only contains a link followed by the search form:{About DuckDuckGo Duck it!} <> <S secure> <X>
So the function looks for the (first) empty text field (
/<>/
), fills it in with the parameters passed to it (i~=0
), activates the second form element on that line (i2*
) and, once the results page has loaded, skips the initial boilerplate (/<Go secure>/+1,+2
) and prints the first 24 lines of results (z24
).Sure. It could be replaced by a single line, replacing all the form interaction with a simple
b https://duckduckgo.com/?q=~0
, but where would be the !!FUN!! in that?
* This is not completely true, as
edbrowse
will show more long-form error messages, but it's pretty inconsistent with them.
† Iff you have JS enabled in your current session. It can be toggled on and off with thejs
command.
‡ I had no luck with the Tildes buttons (e.g., sidebar toggle, upvote button), though, at least not with the version ofedbrowse
that Debian bundles up.10 votes -
New & Experimental CSS Tools in Firefox
8 votes -
What happens when you launch a fresh install of Firefox?
@jonathansampson: What happens when you launch a fresh install of Firefox? I was curious, so I did so with version 68.0.2, and monitored my network activity. Here's what I learned...
23 votes -
New CSS Features in Firefox 68
18 votes -
The GameCube's Lost Internet Browser
19 votes -
100s of tabs: what is there?
Those of you who keep hundreds of tabs open: I'm curious how and why you use them. I'd hoard tabs in the past, but in a sad incident a browser (Firefox) restart caused the loss of all my 10s of...
Those of you who keep hundreds of tabs open: I'm curious how and why you use them. I'd hoard tabs in the past, but in a sad incident a browser (Firefox) restart caused the loss of all my 10s of open tabs that was accumulated over weeks long research about a topic, I decided to never trust tabs again. Now I'm making use of my bookmars toolbar, Org mode and Instapaper for most of the stuff having many tabs open was the method before. So, for me, tabs were for keeping stuff handy during research, read-it-later lists, and temporary bookmarks. What are the use cases for you?
19 votes -
Tor Browser for Android 8.5 offers mobile users privacy boost
3 votes -
Apple arms web browser privacy torpedo, points it directly at Google's advertising model
4 votes -
I challenge you to use Epiphany for a week!
When Edge died, I got worried about loosing competition to the Blink engine and as such, I went exploring other alternatives to realize.. there's not a whole lot, there's blink, gecko and webkit....
When Edge died, I got worried about loosing competition to the Blink engine and as such, I went exploring other alternatives to realize.. there's not a whole lot, there's blink, gecko and webkit.
So with that, I decided to try epiphany - Gnome's web browser. It uses Webkit which is what Blink was forked from so it's not terribly different in theory but the years apart has made that more apparent. It's fairly elegant in my opinion and it lacks some features, sure.
Anyways, to get to what I wanted to do this week, well, I'd like to challenge you all to use it for a week, mostly for bug hunting purposes and possibly to throw ideas at the project. Worth mentioning, I'm not affiliated with the project, just a user.
So to make sure we're all on the same page, we'll use the development Epiphany flatpak, this way we can be sure that the problem is in the current codebase. So, to install it :
Let's install the gnome-nightly repos as per instructions here :
flatpak remote-add --if-not-exists gnome-nightly https://sdk.gnome.org/gnome-nightly.flatpakrepo flatpak remote-add --if-not-exists gnome-apps-nightly --from https://sdk.gnome.org/gnome-apps-nightly.flatpakrepo
Then, let's install the development version by doing so :
flatpak install org.gnome.Epiphany.Devel
Then just launch it and have fun with it!
if you run into any bugs, look at the contribution guide here and report the bugs in the repo after checking that the bug is not already present of course!
12 votes -
Intelligent Tracking Protection 2.1 in WebKit
4 votes -
On building your favourite web browser from source
25 votes -
Let's build a browser engine in Rust! Part 1 of 7
16 votes -
Let's talk browsers
I've tried a lot of browsers. Starting from Chrome, to Chromium, to Firefox, to Links, to w3m, to, eventually, Qutebrowser, which I use for most of my browsing now. At least for me, I had four...
I've tried a lot of browsers. Starting from Chrome, to Chromium, to Firefox, to Links, to w3m, to, eventually, Qutebrowser, which I use for most of my browsing now.
At least for me, I had four things in mind while choosing a browser:
- I want it to be light
- I want it to be minimal
- I want it to be keyboard-oriented
- I want it to be able to use modern websites
I won't be going through all the browsers I've tried, but those I mentioned are the big ones, so I'll just do a quick check-list of these things.
Chrome/Chromium:
- Weighs like a sumo wrestler 1/5
- Cluttered 1/5
- Just some shortcuts and extentions 3/5
- The model, the idol to strife for 5/5
Firefox:
- Apparently lighter than Chromium, though not by much 1/5
- Cluttered 1/5
- Some shortcuts, famous extensions 3/5
- On point 5/5
Links:
- Very light and fast 5/5
- Minimal, though can go smaller 4/5
- Yes 5/5
- Doesn't support javascript 1/5
w3m:
- As light as it gets 6/5
- Pretty damn minimal 5/5
- Even works for blind 5/5
- Does javascript, but hard to use with cluttered wesites like Reddit or any news site 3/5
Qutebrowser:
- It is quite small and feels fast 4/5
- Can be easily modified to not have anything on screen, and command line-like controls 5/5
- Great, but hint system fails with javascript 4/5
- Doesn't work with Reddit, for some reason 4/5
With the things that I look for, Qutebrowser is the answer, with w3m being the close second. Of course, there are different things to look for in a piece of software, and you may want the extra stability and extensions Firefox provides, or privacy of Tor browser, or the suckless nature of surf, so I'd like to hear what is your browser of choice!
17 votes -
Google Releases Security Updates for Chrome (Remote Code Execution?)
5 votes -
Tunneling into a private network through JavaScript
7 votes -
Windows 2000 VM running in the browser with WebAssembly
13 votes -
Are there any good dark browsers for IPhone 4?
I've just used Tildes on my phone for the first time and FUCK! MY EYES! I know I can't change the color of Safari, so I looked in the app store but couldn't find anything. Can you reccomend me a...
I've just used Tildes on my phone for the first time and FUCK! MY EYES! I know I can't change the color of Safari, so I looked in the app store but couldn't find anything. Can you reccomend me a good browser with a dark theme?
5 votes