frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Automatically add missing "async/await" keywords to your TypeScript code

https://github.com/stanNthe5/typescript-autoawait
7•theThree•1y ago

Comments

bastawhiz•1y ago
Is this a problem that people actually have?
xeromal•1y ago
Fun side project man!
primitivesuave•1y ago
I took a peek at the implementation - I think this only works for a case where the typing explicitly contains the string "Promise". For example, I don't think it would work if I use `SomeInterface["some_promise_key"]` or might incorrectly add an async if I use `Awaited<Promise<...>>`.

I think what you're trying to build might be best served by Typescript's VFS - https://www.npmjs.com/package/@typescript/vfs. You can load the local files into an in-memory type system, and quickly extract async/await hints that might be more useful for a typical TS developer. I think there's a lot of really interesting static analysis you could do to improve async/await safety, as it certainly leads to issues from time to time.

joshstrange•1y ago
I do not want to be mean but I think you'd be much better served with ESLint rules to yell at you when you don't await when you should or do when you shouldn't.

This should _not_ be an automatic operation since it can change behavior in ways that will be unclear to the developer (completely undoing any gain from them being added automatically).

theThree•1y ago
You can still control it by adding "//no-await". In fact, the "//no-await" makes me feel more clear.
nextweek2•1y ago
I created a ticket, using comments is not necessary because there is already the `void` syntax for when you don't want to wait:

https://github.com/stanNthe5/typescript-autoawait/issues/1

nextweek2•1y ago
It should be noted that there is already a lint rule for this: https://typescript-eslint.io/rules/no-floating-promises/

Yann LeCun on What Comes After LLMs [video]

https://www.youtube.com/watch?v=ngBraLDqzdI
1•caminante•3m ago•0 comments

Speculative Decoding, Visualized

https://www.adaptive-ml.com/post/speculative-decoding-visualized
1•krackers•10m ago•0 comments

Optimal Elevator Placement

https://jslandy.com/elevators/
1•efavdb•13m ago•0 comments

The "memory shortage" that no one saw coming

https://greyenlightenment.com/2026/07/28/the-memory-shortage-no-one-saw-coming/
1•paulpauper•15m ago•0 comments

OPM finalizes rules expanding its power over RIFs, employee appeals

https://www.govexec.com/workforce/2026/07/opm-finalizes-rules-expanding-its-power-over-rifs-emplo...
1•WaitWaitWha•16m ago•0 comments

Rare footage of humpback whale birth captured on drone video

https://www.cbsnews.com/news/humpback-whale-birth-drone-video/
1•WaitWaitWha•18m ago•0 comments

Send a file from this browser as a stream of QR codes

https://app.transfqr.com
1•mohyware•19m ago•0 comments

His Wedding Guests Were Arriving–Just as His $45B Fund Was Falling Apart

https://www.wsj.com/finance/leopold-aschenbrenner-situational-awareness-ai-fund-597633d3
1•oliver236•21m ago•0 comments

Salmon Hat

https://en.wikipedia.org/wiki/Salmon_hat
2•1659447091•28m ago•0 comments

AI Visibility Evidence Model: Five Factors, Graded by Evidence

https://www.richresults.ai/evidence.html
1•spetschinka•29m ago•0 comments

The year Claude users sued over limits is the year the limits mostly went up

https://okaneland.com/study/claude-code-limits/
2•ermantrout•30m ago•0 comments

Requirements for Interference-Tolerant Radio Altimeter Systems

https://www.federalregister.gov/documents/2026/01/07/2026-00051/requirements-for-interference-tol...
1•Jimmc414•31m ago•0 comments

Explorative Modeling – A new axis for pre-training

https://arxiv.org/abs/2607.27372
3•piesauce•31m ago•2 comments

Looking inside a 1970s PROM chip that stores data in microscopic fuses (2019)

https://www.righto.com/2019/07/looking-inside-1970s-prom-chip-that.html
1•Jimmc414•32m ago•0 comments

Uranium in cobalt-hydroxide exports from the Democratic Republic of the Congo

https://www.nature.com/articles/s41467-026-75910-z
1•Jimmc414•33m ago•0 comments

Freeze the model, train the harness: gains transfer across LLMs and benchmarks

https://www.henrypan.com/blog/2026-07-18-harness-training/
1•megadragon9•33m ago•0 comments

File transfer using animated QR codes

https://www.reddit.com/r/vibecoding/comments/1vawz1e/had_an_idea_for_air_gapped_file_transfer_abl...
2•jv22222•35m ago•1 comments

Proactive V Reactive; from a Startup Founder's Perspective

https://blog.nathanlangley.dev/posts/proactive-ai.html
1•ninjahawk1•37m ago•0 comments

LLM speculative decoding explained simply

https://jwlabs.vercel.app/post/speculative-decoding-first-principles
1•shreybirmiwal•37m ago•0 comments

Benchmark: 68x faster than AWS DMS for real-time CDC

https://www.artie.com/blogs/artie-vs-aws-dms
3•j-cheong•37m ago•0 comments

NoMachine ditches free edition and forums

https://www.reddit.com/r/NoMachine/comments/1vb6y3o/nomachine_ditches_free_edition_and_forums/
1•pacman128•38m ago•0 comments

How to measure the performance of a quantum computer

https://www.ibm.com/quantum/blog/hardware-metrics-2026
1•mrkO99•42m ago•0 comments

Show HN: SmokeVPN – All-in-One WireGuard VPN Hub – Switch Exits in Realtime

https://smokevpn.com
3•lobito25•49m ago•2 comments

Why Journalism Matters to Democracy (2025)

https://cjmd.com.uw.edu/why-journalism-matters-to-democracy/
2•1659447091•50m ago•0 comments

Texas bans THC cannabinoids except delta-9, except edibles and drinks

https://www.khou.com/article/news/local/texas/texas-thc-ban-2026-delta-8-delta-10-hemp-products-l...
4•burnt-resistor•50m ago•0 comments

A Safe Path to Open Weights

https://thinkingmachines.ai/blog/a-safe-path-to-open-weights/
2•stokedmartin•59m ago•0 comments

Readable ad-hoc commands agent skill

https://github.com/a-b/readable-ad-hoc-commands
1•a-b•1h ago•0 comments

How to Exist

https://www.raptitude.com/2026/07/how-to-exist/
5•walterbell•1h ago•0 comments

US Treasury undertakes historic intervention in yen market

https://www.ft.com/content/0f9b2fe7-bde4-4f5f-b49e-93ccb5da9ea8
4•petethomas•1h ago•1 comments

Random Thoughts of Lineage and Death

1•kooi•1h ago•0 comments