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/

AI Glasses Will Impact the Future of Education

https://xg.glass/posts/network-exam-test/
1•__natty__•3m ago•0 comments

Welcome to Sloptopia: The Future of the Internet

https://www.vice.com/en/article/welcome-to-sloptopia-the-future-of-the-internet/
1•Michelangelo11•4m ago•0 comments

Obfuscation: Building the Final Boss of Cryptography

https://vitalik.eth.limo/general/2026/06/29/obfuscation1.html
1•ilreb•8m ago•0 comments

People still want small, personal corners of the web

https://pego.dev/people-still-want-small-personal-corners-of-the-web/
2•felixdoerp•8m ago•0 comments

US Grid Constraints: Towards 40GW+ of Behind-the-Meter Datacenter by 2028?

https://newsletter.semianalysis.com/p/us-grid-constraints-towards-40gw
4•felixdoerp•9m ago•0 comments

A Governance Layer for Agent‑Native Windows RTX PCs (Spark Governance SDK)

https://github.com/Dario-Chang/Spark-Governance-SDK
1•Clickhistrory•10m ago•0 comments

Erin Brockovich on her battle against AI datacentres

https://www.theguardian.com/environment/2026/jun/29/were-up-against-forces-that-have-all-the-mone...
1•trusche•10m ago•0 comments

Putin says Russia will press on front line regardless of Ukraine proposals

https://www.reuters.com/world/europe/putin-says-russia-will-press-with-front-line-campaign-regard...
1•JumpCrisscross•28m ago•0 comments

Show HN: I made a World Cup bracket prediction page, which you can share

https://worldcup.getbestest.com/b/R4acBGSw/
2•pakosteve•28m ago•0 comments

Show HN: Htmx Skills

https://github.com/piyiotisk/htmx-skills
2•piyiotisk•30m ago•1 comments

Notes for June 21-28

https://taoofmac.com/space/notes/2026/06/28/1200
1•rcarmo•30m ago•0 comments

Overton Window

https://en.wikipedia.org/wiki/Overton_window
2•chistev•32m ago•0 comments

Windows 10 support extended until Oct 2027, as users reject Windows 11

https://www.windowslatest.com/2026/06/25/windows-10-support-quietly-extended-until-oct-2027-as-us...
4•tekkertje•33m ago•1 comments

Walnut: A GitHub and Railway Alternative

https://walnut.sh
1•bgwmj•36m ago•1 comments

Anthropomorphic Misalignment research needs stronger evidence

https://www.lesswrong.com/posts/bJcR3yP2avGFuMxyq/anthropomorphic-misalignment-research-needs-str...
1•joozio•42m ago•0 comments

The Trillion-Dollar Borrowing Binge Lifting the Stock Market to Risky Heights

https://www.wsj.com/finance/investing/financial-fraud-paul-regan-9b020a8f
3•JumpCrisscross•46m ago•0 comments

Soumitra Dutta – Expert in Global Innovation and Technology Strategy

https://itif.org/person/soumitra-dutta/
1•davidwilliam26•50m ago•0 comments

Stop cherry-picking, start merging

https://devblogs.microsoft.com/oldnewthing/20180312-00/?p=98215
2•ankitg12•54m ago•0 comments

Everiot - A Modern, Minimal Imageboard, Inspired by 4chan and Reddit

https://everiot.org/
2•gaurana•54m ago•1 comments

Masked Nocturnal Hypertension and Hidden Organ Risk: A Systematic Review

https://www.cureus.com/articles/506093-masked-nocturnal-hypertension-and-hidden-organ-risk-a-syst...
1•bryanrasmussen•55m ago•0 comments

My main Android phone is now 99% Google free

https://simondalvai.org/blog/google-free-android/
2•nosky•55m ago•1 comments

Rural India is different at every level

https://ruralindiaonline.org/
1•grajmanu•59m ago•0 comments

AI Value Capture

https://newsletter.semianalysis.com/p/ai-value-capture-the-shift-to-model
1•nl•1h ago•0 comments

Vibe-Trading: Your Personal Trading Agent

https://github.com/HKUDS/Vibe-Trading
2•grajmanu•1h ago•0 comments

SVG Recolor Tool – Change Color of SVG Online – Free Color Tool

2•freecolortool•1h ago•0 comments

Unifi Network 10.5

https://blog.ui.com/article/introducing-network-10-5
2•janandonly•1h ago•0 comments

After 80 Years, Mathematicians Give Famed 'Erdős Method' an Upgrade

https://www.quantamagazine.org/after-80-years-mathematicians-give-famed-erdos-method-an-upgrade-2...
3•anujbans•1h ago•0 comments

Show HN: Dotdotduck – open-source Web Agent SDK

https://github.com/PerhapxinLab/dotdotduck
2•Lin_Kuei-Kuei•1h ago•0 comments

Replacing Systemd with OpenRC in Debian

https://danielcordova.me/blog/debian-openrc/
3•nogajun•1h ago•0 comments

Greece's Parthenon gets a facelift, revealing a look not seen for 220 years

https://apnews.com/article/greece-acropolis-restoration-parthenon-tourism-da06640fcd747498613d31b...
2•divbzero•1h ago•0 comments