[question] Why the typescript and npm? #1423

Closed
opened 2026-02-16 17:30:55 -05:00 by yindo · 4 comments
Owner

Originally created by @tamis-laan on GitHub (Aug 21, 2025).

Originally assigned to: @thdxr on GitHub.

So I was looking for a solution like Claude code but written in go because I don't want to install any npm javascript related stuff on my machine and I came across opencode.

Now I can see there is golang in there but also Typescript and npm is used. I am wondering, why? Why does this project and many of the other terminal AI code editors use npm?

Surely using go and compiling to a static binary would be the optimal way to go right?

Originally created by @tamis-laan on GitHub (Aug 21, 2025). Originally assigned to: @thdxr on GitHub. So I was looking for a solution like Claude code but written in go because I don't want to install any npm javascript related stuff on my machine and I came across opencode. Now I can see there is golang in there but also Typescript and npm is used. I am wondering, why? Why does this project and many of the other terminal AI code editors use npm? Surely using go and compiling to a static binary would be the optimal way to go right?
yindo closed this issue 2026-02-16 17:30:55 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Aug 21, 2025):

This issue might be a duplicate of existing issues. Please check:

  • #462: User specifically requested static linked binaries instead of NPM dependencies, citing the same preference for Go-only distribution without JavaScript/NPM requirements

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Aug 21, 2025): This issue might be a duplicate of existing issues. Please check: - #462: User specifically requested static linked binaries instead of NPM dependencies, citing the same preference for Go-only distribution without JavaScript/NPM requirements Feel free to ignore if none of these address your specific case.
Author
Owner

@rekram1-node commented on GitHub (Aug 21, 2025):

Bun allows you to compile to single executable, also not using go makes things like plugins much easier. The go tui libs (charm family) have insane performance issues at scale and will soon be replaced with opentui (a zig tui lib with typescript apis)

@rekram1-node commented on GitHub (Aug 21, 2025): Bun allows you to compile to single executable, also not using go makes things like plugins much easier. The go tui libs (charm family) have insane performance issues at scale and will soon be replaced with opentui (a zig tui lib with typescript apis)
Author
Owner

@althafdemiandra commented on GitHub (Aug 21, 2025):

if i recall correctly it was written fully in go and dax decide to rewrite and use typescript to use AI SDK which based on typescript/npm

https://x.com/thdxr/status/1930723995298439275
https://x.com/thdxr/status/1935801226362302730

@althafdemiandra commented on GitHub (Aug 21, 2025): if i recall correctly it was written fully in go and dax decide to rewrite and use typescript to use [AI SDK](https://ai-sdk.dev/) which based on typescript/npm https://x.com/thdxr/status/1930723995298439275 https://x.com/thdxr/status/1935801226362302730
Author
Owner

@rekram1-node commented on GitHub (Aug 21, 2025):

yup thats another reason, AI sdk is super beneficial

@rekram1-node commented on GitHub (Aug 21, 2025): yup thats another reason, AI sdk is super beneficial
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#1423