More relevant than ever: you can find my other social profiles on my website: lcas.dev/. I hope to see many of your there soon!
(no direct links because the almighty overlord blocks them now)
So, Google Chrome gives all *.google.com sites full access to system / tab CPU usage, GPU usage, and memory usage. It also gives access to detailed processor information, and provides a logging backchannel.
This API is not exposed to other sites - only to *.google.com.
This is interesting because it is a clear violation of the idea that browser vendors should not give preference to their websites over anyone elses.
The DMA codifies this idea into law: browser vendors, as gatekeepers of the internet, must give the same capabilities to everyone.
Depending on how you interpret the DMA, this additional exposure of information only to Google properties may be considered a violation of the DMA.
Take for example Zoom - they are now at a disadvantage because they can not provide the same CPU debugging feature as Google Meet.
For those interested: this is done through a built-in Chrome extension that can not be disabled, and does not show up in the extensions panel. Source code is here: source.chromium.org/chromiumβ¦
It is unclear whether the same extension also ships in other Chromium derived browsers.
And for everyone that keeps saying "Use Brave!!!":
Brave also has the same behaviour as Chrome and Edge here. The extension that allows Google to retrieve this information exclusively from *.google.com is also pre-installed in Brave.
I am not kidding: this screenshot is the "proof" that @Oracle provided to @uspto that they are making use of the JavaScript trademark in their products.
@nodejs? Yes! Apparently Oracle's legal team was not up to speed with the fact that Node.js is in fact not an Oracle product.
Web streams are going to be insanely fast in Deno very soon. I'm very excited. β‘οΈπ¦
This code for example will copy no bytes through JavaScript. The entire operation on line 3 happens within Rust, meaning that the JS event loop is completely idle during the streaming itself.
A lot of awesome @deno_land artwork has been made in the last two years. You can find it now at deno.land/artwork πΌ.
β‘οΈ Made something awesome? Add it to the site!
The most recent addition is this 3D render made by MasterJames (github.com/MasterJames).
ALT A 3D scene with a green deno style dinosaur standing in front of a black background, in the rain.
TC39 will now be officially investigating how JavaScript could add support for type annotations!
(the types as comments proposal is now stage 1)
Super exciting!!! π
Awesome work by @robpalmer2, @drosenwasser, @giltayar, and @romulocintra!
JSR source code for frontend+backend, all of our cloud configuration, the docs, and everything else is now open source on GitHub:
github.com/jsr-io/jsr
That's one of the reasons why we are going to file a petition with the US Patent and Trademark Office (@uspto) to relieve Oracle of the JavaScript trademark.
Read the full letter we wrote to Oracle, and sign if you agree with the cause: javascript.tm#FreeJavascript
To be clear, I do not think Google is using this for anything malicious. It is used to display the "CPU usage" graph in the "Troubleshooting" panel of calls on meet.google.com. I don't think it is used for fingerprinting (Google doesn't need that, they have your user ID).
My problem with this is not the capability per se - it's the anti competitive behaviour of only giving this data to google.com by default. For everyone else there is a large hurdle: "Install an extension and ask users to click 'Accept' on scary permission prompts"
The new `Response.json` static method is shipping in @ChromiumDev 105 (stable as of today)! π
You can now easily create a response object with a JSON body.
We shipped support for this new feature in Deno 1.22 in May. It was also recently added to Cloudflare Workers & Node.js
ALT // Before
new Response(JSON.stringify(object), {
headers: {
"Content-Type": "application/json"
}
});
// After
Response.json(object);
Oracle is not even a member of the OpenJS Foundation (@openjsf) - the body that Node.js lives under now. Members of the Node.js technical steering committee that I have talked to can not recall a single Oracle employee actively working on Node.js since 2019 (when this was filed).
Can I interest anyone in a native, HTTP/2 capable, full duplex streaming, web API compatible, and 10-30% faster than Node, HTTP server for Deno?
Deno 1.9 is going to be a fantastic release. Only 5 more days...
ALT Discord message reading "my goodness, to all the deno core team members that have implemented std/testing and Deno.test, thank you so so much. every single day i use it I have flashbacks to how much of a nightmare Jest is to work with and how amazing and fast testing in Deno is"
ALT GitHub issue thread reading:
Msg 1: "HELP ME PLS, ITS STUCKING FOR A LONG"
Msg 2: "and then its fuckin failed"
Msg 3: "help me pls"
β[Deno will be] the fastest JavaScript runtime - full stop. [β¦] The next release of Deno will include a new HTTP server. It is the fastest JavaScript web server ever built.β
Deno go brrrr ππ¦
I've been working on Deno full time for close to two years now. I'm incredibly humbled to be part of this great team, working on this great system.
A little thread π§΅ 1/x
Can we just collectively ack that setting up TypeScript in Node.js in 2022 still requires you to know npm, tsc & wrangling with tsconfig, and the SIMPLEST possible setup that is _just_ setup, no explaining, requires a 3:44 minute video? piped.video/watch?v=H91aqUHnβ¦
$ deno run main.ts
Using prettier right now?
Speed it up 40x by using dprint, which will execute prettier in an embedded Deno JavaScript runtime. β‘οΈπ¦π¦
Read more in Davidβs post π
An example of reducing format checking time with Prettier from ~40s to under 1s on the second CI run via dprint-plugin-prettier.
david.deno.dev/posts/faster-β¦
I am excited to announce that I will be @deno_land's delegate at @TC39.
I am thrilled to be able to work with the many talented people on the committee on pushing JavaScript to new heights, by making the language better for everyone.
Announcing Puppeteer for Deno: a framework to control headless Chromium or Firefox Nightly from Deno.
Create UI tests, take screenshots, generate PDFs, or test Chrome Extensions, all with the same API you are familiar with from Puppeteer in Node.
github.com/lucacasonato/denoβ¦
The import reflections proposal has been approved for Stage 2 in @TC39 plenary! The proposal will allow for importing of WASM modules through the ESM import syntax.
github.com/tc39/proposal-impβ¦
Thanks to the feedback from everyone, and all the work from my co-champion @guybedford!
ALT import module FooModule from "./foo.wasm";
FooModule instanceof WebAssembly.Module; // true
Fresh is a new full stack web framework for Deno. It sends zero JavaScript to the client by default and has no build step. Today we are releasing the first stable version of Fresh. ππ
deno.com/blog/fresh-is-stablβ¦
Mold is soooooo good.
A fresh debug build of @deno_land compiles+links in 1m 22s with mold, and 2m 11s with GCC's linker. Incremental rebuilds are 8s with mold, and 34s with GCC. Absolutely nuts... thanks @rui314github.com/rui314/mold
Do you use @zeithq? Interested in a new modern scripting environment? @deno_land has your back. It's a secure JavaScript and TypeScript runtime written using V8, Rust, and TypeScript. And with the now-deno community runtime you can now use it on ZEIT Now. dev.to/lucacasonato/deno-on-β¦
The v2.1 release of the @code extension for @deno_land now has IntelliSense support for remote deno.land/x imports. It feels really magical πͺ π¦
This is auto complete for remote URLs! π€―
Thanks to github.com/CGQAQ for making this happen!
Oh boy - I just tried it and I can reproduce your result aswell. Good catch. I am getting the blog post updated right now with a disclaimer.
The benchmark in the blog post was ran against 1.45.5, not 2.0.
ALT A screen capture of a Linux terminal with these contents:
$ curl -L https://deno.land/std/examples/curl.ts
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
const url_ = Deno.args[0];
const res = await fetch(url_);
const body = new Uint8Array(await res.arrayBuffer());
await Deno.stdout.write(body);
$ deno compile https://deno.land/std/examples/curl.ts --unstable
Check https://deno.land/std/examples/curl.ts
Bundle https://deno.land/std/examples/curl.ts
Compile https://deno.land/std/examples/curl.ts
Emit curl
$ ./curl https://deno.land/std/examples/welcome.ts
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
console.log("Welcome to Deno π¦");
$ file ./curl
./curl: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=27f138c5f31cda49855498c5e0d59fea5c501054, for GNU/Linux 3.2.0, with debug_info, not stripped
$
2 people in the last 3 days have wanted us to get into blockchains and all the scams surrounding that for Deno. The answer is no, so please stop asking.
You know how Vercel said that the Next.js Edge Runtime would be totally standard, and portable, and such?
Well, Next.js now requires that these "standard" edge runtimes implement the Node.js specific API AsyncLocalStorage API that has no specification π
github.com/vercel/next.js/puβ¦
My grand plan for 2022
1. Join Microsoft
2. Add TSC config option to disable "An import path cannot end with a '.ts' extension. Consider importing './x.js' instead. ts(2691)" diagnostic
3. Quit
Did you know @deno_land uses the same test suite as Chrome, Firefox and Safari to test web APIs? These shared web platform tests ensure that APIs like `fetch` or `URL` are consistent across browsers.
Check out wpt.deno.land/ to view our progress on web compat.
we may or may not have just shipped a new experimental http server that is faster than all other general purpose JS powered web servers, period :)
β‘οΈπ¦π
On jsr.io, all packages are automatically assigned a score based on how well a package is documented, if it has slow types, a description, runtime compat indications, and more. In the future, more factors will go into this score
This score affects search ranking
Did you know that Deno and JSR don't probe during module resolution? This speeds up how fast we can load modules, because we don't need to try 10s of different paths for every import statement before finding the right file on disk.
β¨πͺ Performance πͺβ¨
Ever been frustrated by the web's lack of native support for {en/de}coding of raw data to/from base64/hex?
I am proposing the addition of a new `BinaryDecoder` and `BinaryEncoder` API to add support this common use case right in the web platform.
β‘οΈ github.com/lucacasonato/propβ¦
ALT Javascript code:
```
// EXAMPLE: Calculate a hex sha256 digest of a file
const file = new Uint8Array([/** populated with some data */]);
const digestBytes = await crypto.subtle.digest("sha-256", file);
const digest = new BinaryEncoder("hex").encode(digestBytes);
console.log(digest);
```
ALT Javascript code:
```
// EXAMPLE: decode some base64 data into a Uint8Array
const base64 = `a long string of base64 data`;
const data = new BinaryDecoder("base64").decode(base64);
console.assert(data instanceof Uint8Array);
console.log(data);
```
I love how the @jsr_io logo reassembles itself in a completely different way every time you load the homepage.
There are more ways for the logo to reassemble itself than possible different UUIDs.
Gives such a cool vibe
Actually it doesnβt (at least on a spec level). We discussed this two tc39 meetings ago. Engines currently have to do more total microtask ticks if you return a promise than if you return a non promise value with an await. We discussed how to fix this. Hopefully soon
Open meet.google.com and open the Troubleshooting panel - youβll see a live CPU usage graph that no other website can implement.
Also the code that does this is open source π
Do you enjoy building JS/TS developer tooling, love the web, and enjoy solving hard problems? Do you like writing @rustlang (or want to learn it?)
Come work on @deno_land with our incredible fully remote team: deno.com/jobs/swe
Please DM me if you have questions!
In case you missed it, Deno 1.18 passes more web platform tests for the Web Cryptography API than Chrome, Edge, and Firefox. Only Safari has us slightly beat:
1. Safari (99.8%)
2. Deno (98.1%)
3. Chrome/Edge (94.5%)
4. Firefox (93.4%)
deno.co/webcryptographywpt
Had someone legitimately ask me what the contingency plans for the continued maintenance of a _free_ open source project are after the primary contributor dies (where that contributor is not being paid for that work).
Wtf is wrong with people.
Seriously??? Why do we keep having to make module resolution more and more complex? Please stop it. We have standardised module resolution, stop trying to distance yourselves further and further away from it. :(
JSR is cool ya'll, but WE FINALLY HAVE ITERATOR HELPERS AND SET METHODS!!!! ππ₯³π₯³π₯³π
Thanks @smooshMap and @bakkoting β€οΈβ€οΈβ€οΈ
ALT new Set(["foo", "bar"])
// Set now has intersection and
// difference methods!
.difference(new Set(["bar"]))
// And Set is an iterator, and with
// Iterator Helpers, you can now
// .map those!
.forEach((val) => console.log(val));
Deno KV is not boring KV store. It's a real database with a KV API.
βοΈ Atomic transactions: deno.com/manual@main/runtimeβ¦
ποΈ Secondary indexes: deno.com/manual@main/runtimeβ¦
π¦Ί Strong, external consistency and ACID operations.
And other cool things on their way.
Announcing Deno KV: A Global Database for Global Apps! ππ
β‘ Read data in milliseconds, worldwide
π οΈ Zero setup and zero provisioning
π ACID transactions
π‘ Designed for JavaScript & TypeScript
ποΈ Built on FoundationDB and SQLite
Read more β deno.com/kv
Would you believe me if I told you that I saw a proper, spec compliant HTTP server for JS today (async and everything) that can handle 2x the throughput of any other JS executing HTTP server that exists today?
The future is exciting π
Deno Deploy is about to level up hardβ¦
Canβt wait to show off some of the incredible things the team is working on.
Stay tuned friends.
πͺ π πΎ β‘
π’ π¦ β¨
π β¬οΈ
βοΈ
Remember this? Well Deno is now 400% faster than Node in this benchmark, and thus on par with bun. Also this benchmark is completely meaningless. Who decodes 1 million char long base64 strings? Lol
What do you expect the Content-Length received by the server to be?
await fetch(url, {
method: 'POST',
body: '1',
headers: {
"content-length": "2",
}
});
Going to write a blog post about the architecture behind @jsr_io soon, but some spoilers:
- server side rendered with Fresh
- uses @preactjs islands of interactivity
- no complex RSC / streaming
- runs on commodity cloud hardware
- data in postgres
And look at these numbers π
Like, it is not my problem that your company will stop getting security updates for some free open source project you are relying on but not paying for after I have died. I have bigger fish to fry at that point. Like being fucking dead.
We have so much cool Deno stuff lined up to be released this month. Can't even begin to imagine all the stuff that will be shipped this year. To a great 2022!
We just hit issue #11111 on the @deno_land π¦ repo. Some statistics from the last 3 years:
π€ > 600 contributors, average 25 weekly active
π§ Average of 60 PRs a week
π¦ 4 releases a month
ποΈ Approaching 6000 commits
#β£ 30k JS, 72k TS, 77k Rust LOC
Let's get to #22222! π
We just finished our first JSR working group meeting. We discussed a bit on moving JSR into a foundation, and various other things including finances and roadmap.
More in thread π§΅
No no, it's not Google Meet **like** services. It's only Google Meet. Zoom for example does work, because it does not rely on this *.google.com only behaviour.
doc.deno.land now has a dark mode! No more need to get out your sunglasses while browsing the automatically generated documentation for any Deno compatible JavaScript or TypeScript module. π
Feedback welcome!
ALT A screenshot of the page https://doc.deno.land/https/github.com/denoland/deno/releases/latest/download/lib.deno.d.ts#PerformanceMeasure
Somehow the most popular JS web framework still does not work properly with Node's ESM resolution: github.com/vercel/next.js/isβ¦.
Next has no `"exports"` field in package.json for example. It just papers over this problem by transpiling all of your code to CommonJS all the time :)
It's awesome to be involved in explorations like these that may fundamentally re-shape the way developers write and use JavaScript. I'm excited to bring the experiences from the last 3 years of build-less TypeScript support in Deno to the committee!
Could we have TypeScript with no build step? Could we have types in JavaScript? Maybe!
We're exploring bringing optional type syntax into the JavaScript language!
devblogs.microsoft.com/typesβ¦
Deno stabilized the new URLPattern API in 1.15 last week, and Chrome 95 is shipping with URLPattern support _today_!
Play around with URLPattern in our new Deno Deploy playgrounds: dash.deno.com/playground/urlβ¦
If you have not signed up to Deno Deploy, give it a spin! You can have a simple page deployed globally in less than 10 seconds (with an in browser code editor!).
Visit dash.deno.com/playground/nanβ¦, press "Sign in" and/or "Fork" in the top right corner of the editor, and edit away! π
Itβs the 4 month anniversary for full transparent byte-code caching in Deno!
Deno only parses ESM & CJS code once. All boots after the first use an optimized code cache that doesnβt require us to parse JS again. This makes startup much faster. β‘οΈ
deno.com/blog/v1.43#faster-eβ¦
I am proposing the addition of a `Response.json` static method to the fetch spec. It would allow easy creation of JSON responses in runtimes like Deno, Deno Deploy, or Cloudflare Workers.
Feedback welcome: github.com/whatwg/fetch/issuβ¦