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/

Show HN: Stegcore, steganography and steganalysis in one Rust binary

https://github.com/The-Malware-Files/Stegcore
1•ElementMerc•21s ago•0 comments

Show HN: WPF grade canvas UI framework for the web

1•zionsati•22s ago•0 comments

React Interview Questions Every Developer Should Know in 2026

https://jsdev.space/react-interview-questions-2026/
1•javatuts•2m ago•0 comments

Stop reaching for microservices. You are not Netflix

https://diogocapela.com/blog/stop-reaching-for-microservices-you-are-not-netflix
2•rvz•5m ago•0 comments

Wah-Ult in the Vault

https://www.nature.com/articles/d41586-026-01719-x
1•ilreb•5m ago•0 comments

A Chinese Android just ran a half-marathon faster than any human

https://www.cnn.com/2026/04/19/china/china-robot-half-marathon-intl-hnk
1•ilreb•6m ago•0 comments

Cheaper LLM tokens led to bigger AI bills (Jevons paradox)

https://northwoodsystems.ai/blog/ai-token-economics
1•AndrewLiu96•6m ago•0 comments

Deep Work Plan – Turn a repo into a spec-driven harness for AI agents

https://deepworkplan.com/
1•xergioalex•7m ago•0 comments

€31B drug trade, 7,600 deaths: How the EU plans to tackle the drug crisis

https://www.euronews.com/my-europe/2026/06/16/31bn-drug-trade-7600-deaths-how-the-eu-plans-to-tac...
1•rawgabbit•9m ago•0 comments

AWS Blocks – build AWS apps locally before deploying

https://aws.amazon.com/products/developer-tools/blocks/
1•xyos•9m ago•1 comments

BareMetal OS running inside Firecracker microVMs with <1ms cold start

https://github.com/ReturnInfinity/BareMetal-Firecracker
1•ianseyler•10m ago•1 comments

Function Composition from C++17 to C++23

https://freshsources.com/code-capsules/composing-functions/
1•chuckallison•12m ago•1 comments

Show HN: Kaupang – a push-based deploy CLI, now with a drag-and-drop builder

https://github.com/kaupang-dev/kaupang
1•witnz•13m ago•0 comments

The engineering practices Claude Code and Codex use to improve AI agents

https://www.andrewjesson.com/blog/the-engineering-practices-claude-code-and-codex-use-to-improve-...
1•anndvision•13m ago•0 comments

Git worktrees – why should I use them?

https://github.blog/ai-and-ml/github-copilot/what-are-git-worktrees-and-why-should-i-use-them/
1•onnnon•13m ago•0 comments

Databricks Iceberg Support Has a Catch. It's Called Unity Catalog

https://www.onehouse.ai/blog/databricks-iceberg-support-has-a-catch-its-called-unity-catalog
1•LexSiga•14m ago•0 comments

Show HN: Yet Another News Reader

https://boomerang-news.com
1•messel•15m ago•0 comments

GitHub Action to grade OpenAPI schema quality (A–F) and catch breaking changes

https://github.com/marketplace/actions/typemorph-schema-check
1•jop00004•17m ago•0 comments

Lords urgent question on the suspension of Anthropic's AI models [video]

https://www.youtube.com/watch?v=1Dw_k_Bs95A
1•haritha-j•17m ago•0 comments

HPE Discover 2026 Keynote Coverage

https://www.servethehome.com/hpe-discover-2026-keynote-coverage/
1•ksec•18m ago•1 comments

CLI AI Tool Laucher

https://github.com/tjbmoose09/ai-tool-launcher
2•tjbmoose09•20m ago•1 comments

Show HN: Multiplayer Space Game

https://voidhorizon.net
1•messel•21m ago•0 comments

Writing an echo server in libev and C++ (2011)

https://www.skitoy.com/posts/writing-an-echo-server-in-libev-and-c/
1•mooreds•22m ago•0 comments

Using the stars and paddles, indigenous Taiwanese recreate risky sea journey

https://www.cnn.com/2026/06/17/asia/taiwan-indigenous-paddle-philippines-intl-hnk
1•mooreds•22m ago•0 comments

El Niño is here, so what does it mean?

https://text.npr.org/g-s1-128448
1•mooreds•22m ago•0 comments

What is a data semantic layer?

https://getbruin.com/blog/what-is-a-semantic-layer/
1•arsalann•23m ago•0 comments

"How dare we use something like that..." – Why generative AI artwork is a no...

https://www.gamesindustry.biz/how-dare-we-use-something-like-that-on-someones-dream-why-generativ...
1•dude250711•23m ago•0 comments

Private Tap-to-Pay

https://walt.is
1•627467•24m ago•0 comments

Denmark desperately needs more inequality

https://world.hey.com/dhh/denmark-desperately-needs-more-inequality-8e84a8d0
4•peterspath•24m ago•0 comments

How to make LVT politically doable

https://wilsoniumite.com/2026/06/17/how-to-make-lvt-politically-doable/
2•Wilsoniumite•24m ago•0 comments