[GH-ISSUE #330] Help: Failing to run TypeScript examples on Mac Silicon system #82

Closed
opened 2026-03-02 23:44:25 +03:00 by kerem · 7 comments
Owner

Originally created by @peoray on GitHub (Nov 19, 2025).
Original GitHub issue: https://github.com/anomalyco/opentui/issues/330

bun run src/examples/index.ts

error: Cannot find module '@opentui/core-darwin-arm64/index.ts' from '/opentui/packages/core/src/zig.ts'

Bun v1.3.2 (macOS arm64)

Tried following the docs to run the example, but getting the error above.

Originally created by @peoray on GitHub (Nov 19, 2025). Original GitHub issue: https://github.com/anomalyco/opentui/issues/330 ``` bun run src/examples/index.ts error: Cannot find module '@opentui/core-darwin-arm64/index.ts' from '/opentui/packages/core/src/zig.ts' Bun v1.3.2 (macOS arm64) ``` Tried following the docs to run the example, but getting the error above.
kerem closed this issue 2026-03-02 23:44:25 +03:00
Author
Owner

@kommander commented on GitHub (Nov 19, 2025):

Yeah, you need to checkout a tag for a release and run bun install or have zig and run bun run build from the root. That needs some updating in the docs.

There now also is a prebuilt example standalone executable in the release https://github.com/sst/opentui/releases/tag/v0.1.47 - it's the exact examples from the repo.

<!-- gh-comment-id:3555111487 --> @kommander commented on GitHub (Nov 19, 2025): Yeah, you need to checkout a tag for a release and run bun install or have zig and run `bun run build` from the root. That needs some updating in the docs. There now also is a prebuilt example standalone executable in the release https://github.com/sst/opentui/releases/tag/v0.1.47 - it's the exact examples from the repo.
Author
Owner

@peoray commented on GitHub (Nov 20, 2025):

@kommander I don't quite understand what you mean. I already have zig installed. The command I ran was from /core folder.
Is there something else I need to do?

My goal is to contribute to the Vue package. I don't even know how I can do that or see how to test that as well to be able to contribute

<!-- gh-comment-id:3555134406 --> @peoray commented on GitHub (Nov 20, 2025): @kommander I don't quite understand what you mean. I already have zig installed. The command I ran was from /core folder. Is there something else I need to do? My goal is to contribute to the Vue package. I don't even know how I can do that or see how to test that as well to be able to contribute
Author
Owner

@peoray commented on GitHub (Nov 20, 2025):

Update:

bun run build
$ cd packages/core && bun run build && cd ../solid && bun run build && cd ../react && bun run build
$ bun run build:native && bun run build:lib
$ bun scripts/build.ts --native
Building native prod binaries...
/.cache/zig/p/uucode-0.1.0-ZZjBPpAFQABNCvd9cVPBg4I7233Ays-NWfWphPNqGbyE/build.zig:164:34: error: struct 'array_list.Aligned(u8,null)' has no member named 'init'
    var bytes = std.ArrayList(u8).init(allocator);
                ~~~~~~~~~~~~~~~~~^~~~~
/opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/array_list.zig:606:12: note: struct declared here
    return struct {
           ^~~~~~
referenced by:
    build: /.cache/zig/p/uucode-0.1.0-ZZjBPpAFQABNCvd9cVPBg4I7233Ays-NWfWphPNqGbyE/build.zig:98:78
    runBuild__anon_95475: /opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/Build.zig:2214:33
    12 reference(s) hidden; use '-freference-trace=14' to see all references
build.zig:106:10: error: no field named 'root_source_file' in struct 'Build.TestOptions'
        .root_source_file = b.path("test.zig"),
         ^~~~~~~~~~~~~~~~
/opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/Build.zig:856:25: note: struct declared here
pub const TestOptions = struct {
                        ^~~~~~
Error: Zig build failed
error: script "build:native" exited with code 1
error: script "build" exited with code 1
error: script "build" exited with code 1

I got the error while trying out bun run build from the root folder

<!-- gh-comment-id:3555144342 --> @peoray commented on GitHub (Nov 20, 2025): Update: ``` bun run build $ cd packages/core && bun run build && cd ../solid && bun run build && cd ../react && bun run build $ bun run build:native && bun run build:lib $ bun scripts/build.ts --native Building native prod binaries... /.cache/zig/p/uucode-0.1.0-ZZjBPpAFQABNCvd9cVPBg4I7233Ays-NWfWphPNqGbyE/build.zig:164:34: error: struct 'array_list.Aligned(u8,null)' has no member named 'init' var bytes = std.ArrayList(u8).init(allocator); ~~~~~~~~~~~~~~~~~^~~~~ /opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/array_list.zig:606:12: note: struct declared here return struct { ^~~~~~ referenced by: build: /.cache/zig/p/uucode-0.1.0-ZZjBPpAFQABNCvd9cVPBg4I7233Ays-NWfWphPNqGbyE/build.zig:98:78 runBuild__anon_95475: /opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/Build.zig:2214:33 12 reference(s) hidden; use '-freference-trace=14' to see all references build.zig:106:10: error: no field named 'root_source_file' in struct 'Build.TestOptions' .root_source_file = b.path("test.zig"), ^~~~~~~~~~~~~~~~ /opt/homebrew/Cellar/zig/0.15.2/lib/zig/std/Build.zig:856:25: note: struct declared here pub const TestOptions = struct { ^~~~~~ Error: Zig build failed error: script "build:native" exited with code 1 error: script "build" exited with code 1 error: script "build" exited with code 1 ``` I got the error while trying out `bun run build` from the root folder
Author
Owner

@msmps commented on GitHub (Nov 20, 2025):

@peoray you'll need to downgrade to zig 0.14.1 at the moment

<!-- gh-comment-id:3555171906 --> @msmps commented on GitHub (Nov 20, 2025): @peoray you'll need to downgrade to zig 0.14.1 at the moment
Author
Owner

@kommander commented on GitHub (Nov 20, 2025):

What @msmps said and the vue package needs to move to its own repo, see my comment in #236 for my reasoning.

<!-- gh-comment-id:3555216436 --> @kommander commented on GitHub (Nov 20, 2025): What @msmps said and the vue package needs to move to its own repo, see my comment in #236 for my reasoning.
Author
Owner

@peoray commented on GitHub (Nov 20, 2025):

@kommander I have been able to get it running. Thanks @msmps.

As per the vue package, by another repo, you mean a repo inside of SST or external? If external, I'm happy to do so and make a framework-compatible version of the official maintained libraries

noob question, how can I run the react/solid code to see the examples to compare with the vue codebase?

<!-- gh-comment-id:3555232286 --> @peoray commented on GitHub (Nov 20, 2025): @kommander I have been able to get it running. Thanks @msmps. As per the vue package, by another repo, you mean a repo inside of SST or external? If external, I'm happy to do so and make a framework-compatible version of the official maintained libraries noob question, how can I run the react/solid code to see the examples to compare with the vue codebase?
Author
Owner

@kommander commented on GitHub (Nov 20, 2025):

I mean an external repo.

For react/solid that should be just bun run [example].tsx.

<!-- gh-comment-id:3559413506 --> @kommander commented on GitHub (Nov 20, 2025): I mean an external repo. For react/solid that should be just `bun run [example].tsx`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/opentui#82
No description provided.