HN user

mathias

3,588 karma

Web standards enthusiast. https://mathiasbynens.be/

Posts94
Comments181
View on HN
developer.chrome.com 3y ago

Chrome’s Headless mode gets an upgrade: introducing –headless=new

mathias
5pts2
www.youtube.com 6y ago

Faster Apps with JSON.parse (Chrome Dev Summit 2019)

mathias
1pts0
www.youtube.com 7y ago

What’s new in JavaScript (Google I/O ’19)

mathias
8pts0
mathiasbynens.be 7y ago

JavaScript engine fundamentals: optimizing prototypes

mathias
2pts0
www.youtube.com 8y ago

What’s new in modern JavaScript and V8? (Google I/O ’18)

mathias
2pts0
mathiasbynens.be 8y ago

Asynchronous stack traces: why await beats .then()

mathias
2pts0
labs.tom.vg 9y ago

Browser-based timing attacks: demos

mathias
9pts1
mathiasbynens.be 9y ago

Unicode property escapes `\p{…}` and `\P{…}` in JavaScript regular expressions

mathias
1pts0
mathiasbynens.be 10y ago

ES6 `const` is not about immutability

mathias
1pts0
vagosec.org 11y ago

Security certification services may harm your website

mathias
4pts0
docs.google.com 11y ago

Hacking with DNS

mathias
62pts9
konklone.com 11y ago

Why Google is Hurrying the Web to Kill SHA-1

mathias
423pts131
codegolf.stackexchange.com 12y ago

Regular expression that matches only itself

mathias
2pts1
speakerdeck.com 12y ago

Hacking with Unicode (examples similar to the TweetDeck XSS)

mathias
13pts0
twitter.com 12y ago

Firefox 30 adds support for CSS `line-height` on s

mathias
3pts0
speakerdeck.com 12y ago

Hacking with Unicode

mathias
4pts0
website-archive.mozilla.org 12y ago

The correct abbreviation for Firefox is ‘Fx’, not ‘FF’

mathias
39pts55
hackerone.com 12y ago

Flickr: Invitations disclosure (resend feature)

mathias
317pts90
bas.bosschert.nl 12y ago

Any Android app can read your WhatsApp database

mathias
267pts131
github.com 12y ago

Evil.sh — subtle shell tweaks that will slowly drive people insane

mathias
1pts0
vagosec.org 12y ago

Exploit for PHP Objection Injection vulnerability in WordPress 3.5.1 released

mathias
2pts0
github.com 12y ago

~/.osx updated — sensible hacker defaults for OS X 10.9 Mavericks

mathias
2pts0
mathiasbynens.be 12y ago

JavaScript has a Unicode problem

mathias
3pts0
leannewijnsma.nl 12y ago

Leanne Wijnsma is documenting her 484m² garden 1:1 using a flatbed scanner

mathias
19pts7
mathiasbynens.be 12y ago

Processing Content Security Policy violation reports in PHP

mathias
1pts0
kitcambridge.be 12y ago

Lo-Dash v2.0.0 released — supports custom builds

mathias
2pts0
vagosec.org 12y ago

Object injection vulnerability enables remote code execution in WordPress 3.6

mathias
48pts19
an.enduringcolumn.com 12y ago

Exceptional exception handling

mathias
1pts0
mathiasbynens.be 12y ago

Hiding JSON-formatted data in the DOM with CSP enabled

mathias
3pts1
gist.github.com 12y ago

Things that broke with the Opera 15 release due to the switch to Blink/Chromium

mathias
43pts9

Did you know that “old” Chrome Headless (2017–2023) was a separate, alternate browser implementation that just happened to be shipped as part of the same Chrome binary? It doesn’t share any of the Chrome browser code in //chrome.

--headless=new in Chrome 112 on the other hand works the way you'd expect.

Author of the referenced article here.

The article includes a working polyfill that includes old IE support, so I’m not sure what you’re complaining about.

Also, saying “jsvu is the justification for the polyfill” doesn’t make much sense. jsvu is just how I happen to test in various standalone JavaScript engines. There are other, non-jsvu ways of getting such binaries, e.g. compiling one yourself, and there are JS engine binaries that jsvu doesn’t provide (Rhino, Ringo, Nashorn). jsvu usage does not correspond to anything you seem to be talking about, and comparing its download count with IE10 usage is one of the more extreme apples-to-oranges comparison I’ve seen. ️

V8 release v7.2 8 years ago

We do indeed measure improvements against more than one website. We wouldn’t want to improve website X while regressing the rest of the internet. See https://v8.dev/blog/real-world-performance (from 2016):

We now monitor changes against a test suite of approximately 25 websites in order to guide V8 optimization. In addition to the aforementioned websites and others from the Alexa Top 100, we selected sites which were implemented using common frameworks (React, Polymer, Angular, Ember, and more), sites from a variety of different geographic locales, and sites or libraries whose development teams have collaborated with us, such as Wikipedia, Reddit, Twitter, and webpack. We believe these 25 sites are representative of the web at large and that performance improvements to these sites will be directly reflected in similar speedups for sites being written today by JavaScript developers.

Hey, I’m the author of the article. Despite its age, it’s still accurate and up-to-date.

these features aren't entirely new

Depends on what you mean by that. These features are still not universally supported by all modern browsers, for example, so I can imagine they’re still new to a lot of developers.

Chrome supports all these features (except for String#matchAll, which is currently at Stage 3). Other browsers don’t yet support the full set, but they’re all working on getting there.

Ten years of V8 8 years ago

That would be a Chromium feature. V8 only implements ECMAScript and WebAssembly.

Which means you can’t practically use the new form without feature detection.

That does not follow.

`{ capture: true }` works in both, since it’s an object, and thus truthy.

There’s no need for feature detection in the case you describe.

Sadly, that’s the whole premise of this article.

It’s only a problem if you want `capture: false` combined with other options — since you’d need to pass in an object, that would be truthy in the old implementations expecting a boolean instead. But then again, the additional options wouldn’t be supported in those old implementations either.

I’m confused — what’s the actual use case that’s breaking here?

That’s not equivalent though — in the article’s example, imagine `element` is `undefined`, for example. `then()` wouldn’t be called in that case.

That’s true for client-side JavaScript (like I said in the presentation).

It’s a whole different story if you’re using server-side JavaScript (e.g. Node.js), though.

It looks like this is possible because there is not an explicit 'access-control-allow-origin' header set on facebook

CORS has nothing to do with it, actually. This is where the strength of the attack lies.

The point of typing a message in a webmail UI and sending it is to deliver the exact message you entered to the recipient. Adding hard line breaks, effectively altering the original message, is not useful.

Making text fit on a 80-character fixed-width screen is not something the email sender should do; the recipient’s email client should do it based on their preferences.