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/

Amazon Basics, but for Intellectual Property

https://idiallo.com/blog/amazon-basics-but-intellectual-property
1•firefoxd•39s ago•0 comments

EO 14412: Official Post-Quantum Transition Deadlines

https://www.appviewx.com/blogs/executive-order-14412-post-quantum-imperative-for-machine-identity/
1•mooreds•50s ago•0 comments

Show HN: Dike is a compliance gateway for AI products in the EU

https://d1k3.com
1•orbanlevi•2m ago•0 comments

The Carney government's expanding power to identify Canadians online

https://thehub.ca/2026/07/06/the-carney-governments-expanding-power-to-identify-canadians-online-...
1•Teever•2m ago•0 comments

Show HN: DemandMap – Memory Mapping S3 into Polars on macOS Without FUSE

https://github.com/sonthonaxrk/demandmap
1•sonthonax•7m ago•0 comments

Common prefix skipping adaptive sort

http://smalldatum.blogspot.com/2026/01/common-prefix-skipping-adaptive-sort.html
1•theanonymousone•8m ago•0 comments

Open Hands has a pretty Repo Visualization

https://www.reddit.com/r/PrincipalAi/s/eRRiNWjCft
1•fernando-ram•9m ago•0 comments

Bulletproof Hosting

https://en.wikipedia.org/wiki/Bulletproof_hosting
1•mmarian•9m ago•0 comments

Show HN: A little cat that counts your tokens (Claude and codex)

https://jpthecat.com
1•saddington•13m ago•0 comments

Spain's Solar Is So Cheap Investors Are Looking for an Exit

https://www.bloomberg.com/news/newsletters/2026-06-30/spain-s-solar-is-so-cheap-investors-are-loo...
2•mooreds•13m ago•1 comments

Ask HN: What browser extensions or front ends do you use for reading HN, if any?

4•GaryBluto•13m ago•3 comments

Show HN: DNSskills.md – agentic skills for certain DNS utilities

https://dnsskills.md
1•StuntPope•13m ago•1 comments

The Yoto Music Box Is a Ray of Hope Amid the 'Techlash'

https://www.nytimes.com/2026/07/01/technology/personaltech/yoto-music-box-screens.html
1•reaperducer•14m ago•0 comments

Ekka: Automated Diagnosis of Silent Errors in LLM Inference

https://syfi.cs.washington.edu/blog/2026-06-29-ekka/
2•matt_d•16m ago•0 comments

You Don't Know Jack About Formal Verification

https://queue.acm.org/detail.cfm
3•aravindputrevu•16m ago•1 comments

I'm playing around with SEO / AEO / GEO

https://www.youdidwhatwithai.com/
2•thewebuiguy•18m ago•0 comments

"What is the terminal?" – Jon Udell

https://blog.jonudell.net/2026/07/01/what-is-the-terminal/
2•rbanffy•18m ago•0 comments

A Mind, a Body, and a Place to Work

https://twitter.com/maurya_ian/status/2074010518650864073
2•mauryaudayan•19m ago•0 comments

Guest Post: Atari Origins – By Mark Miller

https://www.goto10retro.com/p/guest-post-atari-origins
2•rbanffy•19m ago•0 comments

Alice Sebold, the wrong man, and Syracuse's buried rape crisis

https://www.propublica.org/article/alice-sebold-anthony-broadwater-rape-exoneration-syracuse
3•Jimmc414•19m ago•0 comments

XGBoost beat LLMs at finding civilian-harm posts in Ukraine war Telegram data

https://www.bellingcat.com/resources/2026/06/25/how-to-use-ai-to-help-find-civilian-harm-conflict...
2•Jimmc414•20m ago•0 comments

AMD Ryzen AI Halo Is a Powerful Mini PC with Open-Source Software

https://www.phoronix.com/review/amd-ryzen-ai-halo
2•rbanffy•20m ago•0 comments

Judgment-Theater and Responsibility Laundering in AI Post-Training

https://medium.com/@wo.shen.me.dou.bu.zhi.dao.a/structural-audit-of-judgment-theater-and-responsi...
2•SyntagmaNull•20m ago•0 comments

DeepSeek V4 Is Earning Agentic Token Share

https://openrouter.ai/blog/insights/deepseek-v4-adoption/
3•verdverm•20m ago•0 comments

Bugs Happen: solo PQ compared to ECC+PQ

https://blog.cr.yp.to/20260704-bugs.html
1•aburan28•20m ago•0 comments

Tokentap – Print what your LLM is thinking

https://github.com/jmuncor/tokentap
1•jmuncor•21m ago•1 comments

From Trust to Verification: Lean's Impact on Mathematics

https://www.simonsfoundation.org/2026/06/23/from-trust-to-verification-leans-impact-on-mathematics/
1•digital55•22m ago•0 comments

5 frontier LLMs have the same favorite joke

https://rkique.github.io/humanitys-first-exam/joke
1•rkique•23m ago•0 comments

IOL-AI 2026 Challenge: Can Your Model Solve Linguistics Olympiad Problems?

https://huggingface.co/spaces/iol-ai-challenge/iol-ai-2026
1•amarbirsingh•23m ago•0 comments

DGX Spark Local LLM Benchmark: Administrative Tasks

https://www.aai-labs.com/en/research/local-llm-benchmark-administrative-tasks
1•tasubotadas•25m ago•0 comments