acutmore Profile Banner
Ashley Claymore Profile
Ashley Claymore

@acutmore

Followers
989
Following
10K
Media
282
Statuses
5K

Writing TypeScript at Bloomberg - JavaScript Infra & Tooling team. TC39 delegate. Opinions be mine. https://t.co/a4nOS1vefs 🌈

London, UK
Joined March 2009
Don't wanna be here? Send us removal request.
@acutmore
Ashley Claymore
6 years
So. a joke with a colleague at work got a little bit out of hand. I wrote a 4-Bit Virtual Machine in @typescript, using just Types, no JavaScript.
Tweet media one
12
143
646
@acutmore
Ashley Claymore
3 months
RT @mattpocockuk: Here's why the Records and Tuples proposal died, and how Composites might solve it. I did my homework for this one - I i….
0
30
0
@acutmore
Ashley Claymore
8 months
My talk on ts-blank-space is now online (35min).
@acutmore
Ashley Claymore
11 months
Today, I'm releasing a TypeScript compiler called ts-blank-space 🎈. We use this at @TechAtBloomberg to perform type-stripping on a modern subset of TypeScript. It's written in TypeScript and is fast because it uses whitespace to enable work-skipping.
Tweet media one
0
5
48
@acutmore
Ashley Claymore
11 months
πŸ“’ If you wish to learn more, I'll be giving a talk on ts-blank-space in two weeks!. The London TypeScript Community Meetup is being held at the @TechAtBloomberg London Office where I work on Wednesday 2nd October. Sign up now: #opensource.
go.bloomberg.com
0
2
17
@acutmore
Ashley Claymore
11 months
For our use case, ts-blank-space works great. I'm also impressed @kdy1dev was able to adopt this approach so quickly in SWC. Let me know what you think and please raise any issues you find on the repo!. #opensource.
Tweet card summary image
github.com
A small, fast, pure JavaScript type-stripper that uses the official TypeScript parser. - bloomberg/ts-blank-space
2
0
19
@acutmore
Ashley Claymore
11 months
There are some limitations to the type-stripping approach used by ts-blank-space, so it won't work on all @TypeScript projects. These features are not supported:. ❎ <>-style type assertions.❎ CJS-specific syntax (import =).❎ enums, namespaces, parameter properties
Tweet media one
3
1
22
@acutmore
Ashley Claymore
11 months
This work-skipping makes ts-blank-space very fast. We've seen it operate 5.6x faster than classic tsc πŸ”₯. We reuse the official TS parser, so the only difference is the JS emit. Using this parser also means we retain access to the AST for other operations, such as custom linting.
Tweet media one
1
2
27
@acutmore
Ashley Claymore
11 months
However, the work-skipping goes beyond codegen. Because original code locations are preserved, there's no need to generate a sourcemap at all!. This is good for both performance and maintenance. ts-blank-space is also tiny: only 700 LoC 🀏.
1
0
22
@acutmore
Ashley Claymore
11 months
ts-blank-space deletes the types and replaces them with spaces. This form of type erasure means the runtime code stays in its original location. We use the parser's AST only to help us find type coordinates - there is no need for traditional codegen!.
Tweet card summary image
github.com
A small, fast, pure JavaScript type-stripper that uses the official TypeScript parser. - bloomberg/ts-blank-space
1
4
29
@acutmore
Ashley Claymore
11 months
Today, I'm releasing a TypeScript compiler called ts-blank-space 🎈. We use this at @TechAtBloomberg to perform type-stripping on a modern subset of TypeScript. It's written in TypeScript and is fast because it uses whitespace to enable work-skipping.
Tweet media one
13
85
392
@acutmore
Ashley Claymore
11 months
RT @robpalmer2: TypeScript excitement πŸ˜‰. πŸ“’ It's finally happening! Come visit us in London for a free evening of top-tier TypeScript talks.….
0
5
0
@acutmore
Ashley Claymore
11 months
RT @alistaiir: #TypeScript London is returning in October!. πŸ“… October 2nd, 2024.πŸ—ΊοΈ Bloomberg HQ, Queen Victoria St. Three exciting talks fr….
Tweet card summary image
guild.host
Oct 2nd 6:00PM: \[CLICK HERE TO REGISTER TO ATTEND ON THE BLOOMBERG WEBSITE] https://go.bloomberg.com/attend/invite/london-typescript-community-meetup/
0
23
0
@acutmore
Ashley Claymore
11 months
I thought the "just JavaScript" part of React was: there isn't new syntax for `if` and loops within the template (JSX). Any logical aspect should be achieved with "just JavaScript".
1
0
14
@acutmore
Ashley Claymore
1 year
Test fixtures for code transforms containing things I can't un-see
Tweet media one
0
0
7
@acutmore
Ashley Claymore
1 year
RT @robpalmer2: ECMAScript explanations πŸ˜‰. The annual treatment returns with @marypcbuk thoroughly delving into the details of @TC39's ES20….
Tweet card summary image
thenewstack.io
Our analysis of the small but helpful features in the latest annual JavaScript release, including easier WebAssembly integration.
0
15
0
@acutmore
Ashley Claymore
1 year
Could _jsx differ between the static and dynamic part of props?.Or maybe looping over all the props isn't as expensive as I'm imagining.
0
0
0
@acutmore
Ashley Claymore
1 year
RT @alistaiir: Pleased to share that #TypeScript London<T> is returning!. We'll be announcing a meetup evening soon. If you're interested,….
Tweet card summary image
guild.host
Unofficial TypeScript guild for Londoners https://x.com/robpalmer2/status/1791519681397809228
0
11
0
@acutmore
Ashley Claymore
1 year
I dunno. A double edged sword sounds much easier to use.
1
0
3
@acutmore
Ashley Claymore
1 year
Is it too late to have:.let TAU 4eva= 2*PI;.
0
0
1
@acutmore
Ashley Claymore
1 year
RT @johnny_reilly: Walked in with @acutmore this morning. The company was delightful. The weather. was British
Tweet media one
0
1
0
@acutmore
Ashley Claymore
1 year
After spending a week going through the new errors when checking with TypeScript 5.4. My biggest take away is: in many cases an explicit type annotation, especially at module boundaries, would have made my task much easier 😎.
@robpalmer2
Rob Palmer
1 year
The TypeScript tooling used by @TechAtBloomberg checks our internal package ecosystem to identify breaking changes in new versions of TypeScript. We check each major release & publish a report. Thanks to @acutmore for reviewing TS 5.4 Beta πŸ‘.
1
0
11