Husband, Father, Developer, Gamer. I worked on @TypeScript at @Microsoft. Delegate to @TC39. All opinions are my own. he/him fosstodon.org/@rbuckton

Pennsylvania, USA
After 18 years at Microsoft, with roughly a decade of that time working on TypeScript, I have unfortunately been let go in the latest round of layoffs. I need to take a few days to process before I start looking for work. Thanks to everyone who's been part of my journey so far.
1,039
2,460
48,659
6,144,442
LinkedIn locked my account for some reason and it's going to take several days to sort out. If you're trying to reach me there, you may want to try on here or on bluesky instead.
20
7
167
21,007
I made a thing
Today the TypeScript team is releasing a new VS Code extension named Deopt Explorer! This tool can help find polymorphism and deoptimizations in your code, and it's already helped us speed up TypeScript itself. Check out what we've built! devblogs.microsoft.com/types…
12
6
137
23,881
After taking some time off and spending the summer with my kids before they go back to college, I'm happy to announce that I'll be starting a new role at @F5 next week! Thanks to everyone that reached out over the past few months. I'm very much looking forward to what's next!
1
2
72
10,612
I'm happy to announce that Explicit Resource Management has (conditionally) advanced to Stage 4 at TC39 today. Advancement is pending final PR approvals on the spec text and a few outstanding Test262 tests. github.com/tc39/proposal-exp…
1
10
68
12,711
Replying to @mattpocockuk
I and a few other TC39 delegates have been thinking for awhile on what a native implementation of enums might look like, as well as possibly expanding enums to include ADT enums, similar to Rust. I'm curious what thoughts you might have on that. github.com/rbuckton/proposal…
4
4
57
10,400
Today marks 15 years at Microsoft. In that time I've worked on a bunch of great projects including product feedback tools, MSDN, VS Online, the IE F12 Dev Tools, and TypeScript, and I've worked with some amazing people along the way!
4
1
49
Replying to @code
Where was this tweet an hour ago? It would have been perfect with these:
I can get behind these ideas.
37
Class `static` initialization blocks achieved Stage 4 consensus today at #TC39! 🚀🚀🚀 Provides access to private state and multi-step field initialization inside of a `class` declaration. Thanks to all the reviewers and everyone else involved! github.com/tc39/proposal-cla…
1
10
45
'enum' is now a Stage 1 ECMAScript proposal: github.com/rbuckon/proposal-…
3
3
37
127,384
We introduced the `intrinsic` keyword used by type aliases like `Uppercase<T>` long after `keyof`, though I think having type operators like `keyof` is necessary to have the building blocks needed to create more advanced type aliases.
2
1
24
14,515
I can get behind these ideas.
1
2
27
Last day in Seattle! Wife, kids, and I are moving back east to be closer to family (and to get away from the dreary weather 🌧️). Don't worry though, I'm still working on TypeScript for MS. The only thing that will change is I'll be more awake for early morning TC39 meetings.
26
There's an obvious @AviationGin product placement in Red Notice and I'm not even mad. I pretty much expected it. Wouldn't be surprised if the whole movie is just an extended @VancityReynolds commercial. ...which, if I'm being honest, I still probably would have watched.
1
22
I'm doing some research for future @TC39 proposals to add additional features to regular expressions. I'm putting together feature comparisons for all major RegExp engines at rbuckton.github.io/regexp-fe… and you can help. PRs to add new engines and fix mistakes are welcome!
2
8
22
Replying to @BenLesh
I imagine it's easier to explain `<font>` than dig into CSS at what seems to be a fairly high level course. Then again, they could have just left changing color out of the class until they *were* at the point of introducing CSS...
4
17
I've been trying to push F#-style since the initial proposal (which *was* F#-style), and I proposed partial application at around the same time. (I'd intended to propose `|>` along with partial application, but @littledan beat me to it 😊).
2
17
Replying to @alysjones96
I'm sure they have a copy in there somewhere.
17
1,465
Today my wife and I have been married for 21 years. Our marriage is now legally old enough to drink in the US.
2
16
This documentary is amazing and reminds me why I love working on this project. The community is outstanding! It's been an honor to have been part of all of the hard work and effort that got us to where we are right now.
1
1
14
4,296
Hah! Jokes on you. My friends already use Bing. I mean, yeah, it just so happens that they *also* work for Microsoft.
Microsoft Worker Still Thinks He Can Convince Friends to Use Bing: bit.ly/3cY92wY
1
3
15
Have you been reading too much "He Who Fights With Monsters"? Main character is isekai'd to a fantasy world of magic and monsters and everyone has mostly normal sounding names like Neil or Amanda, and there's an Apocalypse Beast named Colin.
3
10
Replying to @JenMsft
I just bought this shirt for one of my kids a little over a month ago
2
13
Replying to @shanselman
Can you even read Dune "casually"? Some have tried... "so many, but none have succeeded." "They tried and failed, all of them?" "Oh, no." She shook her head. "They tried and died."
1
10
Apparently, in the Stranger Things universe C# and .NET existed in 1986, though I think there's a syntax error on line 7...
1
2
12
Replying to @shanselman
Followed roughly 15 minutes later (once the presentation has ended) by: "umm... We can *still* see your screen. You might want to stop sharing."
1
9
Replying to @mattpocockuk
What kinds of benefits do you believe native enums would bring to JS?
2
11
963
In addition, we implemented the `readonly` type operator for arrays (and tuples) *after* `Readonly<T>` because otherwise you could still push/pop an array. Having `Readonly<T>` special-case arrays using a conditional would have made the type unusable.
1
11
1,194
My first TC39, I'd been invited by @lukehoban to talk to @wycats about my version of the Decorators proposal. Between myself, Yehuda, @jntrnr, the Angular folks, @littledan, @pzuraq, and everyone else who worked on it, it's so great to see it so close to the finish line.
8
944
Also, Decorators in JS hit a wall as the three largest runtimes are refusing to implement the Stage 3 proposal.
6
11
15,864
I think I've read the book enough times over the last few decades that I am prepared for this film.
2
10
Replying to @wesbos
I wonder what typeof food they serve there.
1
9
Replying to @buildsghost
class C { static magic = true; } typeof C; // "function"
1
11
Replying to @MylesBorins
Welcome to the cosmere!
1
98
I'd still favor `keyof T` over `Keyof<T>` were we to do it over again. `intrinsic` isn't actually very flexible in the type system right now anyways (it only works for `string -> string` transformations).
1
10
1,697
Replying to @ljharb @BenLesh
There's an easier way: typescriptlang.org/play?#cod…
2
2
10
3,761
Replying to @mycoliza
I'm pretty proud of the one I wrote at the top of this file, though it doesn't have the fancy line art: github.com/microsoft/TypeScr…
9
Unfortunately I won't be at @TypeScriptConf this year, but I'm excited that I'll be helping my daughter move into her dorm for her first year at college! Enjoy the conference everyone.
9
Minor clarification: We've had @‌template support for JSDoc in JS for some time. This change adds support for type parameter defaults:
1
8
I'm not saying I've been tinkering with a JS parser in the TS type system... ...but I've been tinkering with a JS parser in the TS type system.
3
7
Replying to @davidfowl
For most things, yes. For state ID, no. I'd be concerned about this scenario: Officer: "I need to see your ID" Person: *unlocks phone, opens wallet app to show ID* Officer: *takes phone to verify ID, now has unfettered access to device w/o pesky 5th amendment issues*
6
1
6
Also, `import {Direction} from...` is arguably better than hard coding values as package authors can make changes to enums and hang deprecation comments on outdated members.
8
1,081
Someday I will look back and think "TC39 played a major part in my supervillain backstory".
1
8
I've thought it might be cool to be @premiumbusiness, but given the new policy I'm not sure I'll qualify. Maybe we can start a compiler development esport and register @typescript as a competitive team?
8
Now is a good a time as any to get back into making pizza. First homemade hand-tossed pizza I've made in about 5 years.
1
5
8
Replying to @satanacchio
If you want to send me a DM I'd be happy to discuss my current thinking on the proposal. I've been working on an updated version that I hope to post soon.
6
115
Replying to @JenMsft
I mean, the art department expecting to take the blame for management rushing their design seems about right.
1
5
Congrats to my middle daughter who graduated today with both her high-school diploma *and* an Associates Degree in Arts & Sciences with high distinction!
7
There are some types, like `Awaited<T>`, `Exclude<T>`, and `Extract<T>`, that would be better as a type operator. Conditional types like those can often be a pain due to limitations with comparability.
1
7
1,277
Is this modded or are those just shaders? Must be with RTX ON
6
Replying to @rauchg
I think Observable belongs in TC39, tbh. There is already a proposal for it but it hasn't been touched in years: github.com/tc39/proposal-obs…
2
7
700
My RegExp Match Indices proposal (github.com/tc39/proposal-reg…) is now shipping in nightly builds for 3 major browsers! - Chrome Canary 91 - Firefox Nightly 88 - Safari Tech Preview 122 🚀🚀🚀 Thanks to everyone who helped made this a reality. Now on to more RegExp features!
1
7
A union of literals provides little to no support for quick info/documentation in an editor. Enums give you a place to hang documentation as well as a logical grouping of related values. Enum + decorators + JSON replacer/reviver=flexible serialization. Or just use string values.
2
7
1,678
Replying to @cassidoo
Despite that quote, Byakuya came across as quite arrogant for much of the series. I was always more of a Kenpachi fan.
2
7
Replying to @shanselman
Ah yes, cloud autosave. Especially useful when you paste unicode characters into an app that cause it to crash, but only after they've been synced to the cloud so that every time you open the app it crashes. On. Every. Machine.
7
Correct. `using` is block scoped and invokes dispose at the end of the block.
7
209
6
Last night my daughter was accepted into her dream college. In her excitement she danced around like @Lin_Manuel in @HamiltonMusical getting invited to the Constitutional Convention, pantomiming the coat-tail flip and all.
6
And here I thought it would have been something more innocuous, but no. Mine was async functions in TS.
1
5
Replying to @shanselman
I don't have a StreamDeck, but I've been playing around with obs-websocket and an electron app that essentially does the same thing running on a Surface Pro (pictured below). One of these days I'll get around to putting the sources on GitHub...
4
6
Replying to @buildsghost
`object` is the non-primitive type. `{}` isn't non-primitive, since it uses structural typing. There's some oddity between `typeof` and types, since `null` is typeof "object" but type `null`, and function is typeof "function" but is in the domain of type `object`.
6
Replying to @AdamRackis
it's weirdly inconsistent that the above is an error but for (let x in null) {} is not.
1
6
258
Proud of my 17 year old daughter. Friday: she played viola at Benaroya Hall in Seattle as part of a professional symphony orchestra. Saturday: she won a gold medal at The Revolution BJJ competition in the adult women's blue-belt division. She's a bit of an overachiever. 🙂
1
5
Hyperfocus be like
5
Replying to @shanselman
My old office in Building 4, circa 2012:
4
Array.prototype.<literally anything> = function () {}
What is the programming equivalent of a kid touching a hot pan?
1
5
3,035
Replying to @mattpocockuk
One of my early goals with github.com/rbuckton/proposal… was to look at ways to codify reverse lookup so that we didn't conflate the enum declaration itself with its inverse mappings. i.e., use `Enum.getName(AlbumStatus, 0)` or `Enum.getName(AlbumStatus, "new_release")` instead.
1
4
472
If getConnection itself is async, you await getConnection. If it's *cleanup* is async, you use `await using`. Also, neither `using` nor `await using` support destructuring, so if both parts are async it's: await using connection = await getConnection();
1
5
13,043
I think the trick is, if you're going to go with run of the mill, everyday names in your epic fantasy or sci-fi series, just go all in with it. Make a few in-jokes about the absurdity of naming the God Emperor "Tim", and you're good.
1
4
Replying to @elchefe
One of the reasons I started following was because my daughter does BJJ, a.k.a. "The Martial Art of folding clothes while people are still wearing them". She's always been an amazing competitor, so pandemic restrictions have been hard on her the last year.
4
Replying to @BenLesh
As an Influencer? I looked into it and I guess I need a Wikipedia article about me or something. Championing a proposal to Stage 4 at TC39 doesn't seem newsworthy enough to get on Google trends.
1
5
You should only use .d.ts to represent other people's code (runtimes, packages, etc.), never your own code, and you publish your .d.ts outputs so that others can do the same. The split between .ts and .d.ts should be the package boundary.
2
1
5
470
Replying to @qntm
As to why he gave her a chance, it's probably a "magical beings have to follow rules" thing. en.m.wikipedia.org/wiki/Laby…
1
4
Alright, I did it! I finally got around to publishing this after a lot of cleanup and dependency updates. Only building for Windows in nightly, but hope to change that soon. Give it a try if you use OBS studio and have a spare tablet lying around: github.com/rbuckton/obs-remo…
Screenshot of the app in demo mode. The current scene updates multiple times a second, can show/hide scenes, has a light/dark mode, and quick access to mute audio inputs.
1
1
5
Weekend project: Replacing the head unit on my car with an Android system w/navigation. Dont know much else about cars, but I at least know how to do this.
2
5
Replying to @samgoodwin89
Reserved functionality, there wasn't a clear idea of how best to handle it and they didn't want to repeat the necessity of `this` type checking in the constructor that ES5-style "classes" had. You could use Decorators to makwle a class callable, but that's not well typed in TS.
1
5
943
For someone who is against working from home, Elon really seems to want twitter employees to just live at the office.
5
Replying to @philnash
Now do one about NFT fanboys who disabled right-click and Missouri state officials coming together over the belief that F12 is hacking.
5
Replying to @davidfowl
The decorators proposal for JavaScript is heavily influenced by Python decorators, C# Attributes, and Java annotations. These are exactly the kind of use cases I imagined when we added expirmental support for decorators to TypeScript.
5
Just had my 3rd power outage in the last 24h. What's the deal @PECOconnect?
1
4
11,103
Replying to @LichtmanLabs
The music video for "Buddy Holly" was included in the Windows 95 install CD.
1
4
Replying to @threddyrex
But then you miss out on Web for Workgroups 3.11.
4
Replying to @samgoodwin89
Because you can't call a class, even with new.target? You sort of could when you down level to ES5, but actual classes in ES2015 and up throw when you call them as functions.
1
4
789
Replying to @buildsghost
I've been thinking about it as well at github.com/rbuckton/proposal… @drosenwasser (for the pattern matching side)
2
4
It's more that it only tests *own* properties, so if an object has an *inherited* property with the provided name, hasOwnProperty would return false and we would incorrectly narrow as we make no distinction between own vs. Inherited in the type system.
3
4
90
Christmas #tabletop gaming haul. This is just the stuff my wife and kids got me, or that my wife and I got for the family and doesn't include the games we got just for them. We like our games in this house.
1
3
1,815
Replying to @threddyrex
I sometimes say "Putting on my TC39 hat" when talking about standards in TypeScript meetings. The hat:
4
I imagine ADT enums and Extractors/pattern matching would be a good fit for this. I'll weigh in on the issue later, but Array/iterator destructuring is considerably slower than object destructuring since, IIRC, no runtimes currently optimize Array destructuring.
2
4
84
Replying to @sophiajturner
Don't lose sight of what's important.
4
Replying to @bterlson
"You must construct additional Azure VMs"
4
And yes, it's all written in @TypeScript
4