Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
staltz authored May 19, 2023
1 parent c74175d commit f68ba98
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ Test this project like this:
3. `npm run build` (will compile the Zig project and produce `dist/lib.node`)
4. `npm run test` (will call the `greet()` function from Zig)

[Potential update to Zig 0.11](https://github.com/staltz/zig-nodejs-example/pull/2)

## Why Zig?

Writing C/C++ in 2021 is difficult, confusing, verbose, antiquated. (Disclaimer: I have written many thousands lines of code of C/C++ in my lifetime, I know what I'm talking about) But writing native Node.js modules is a superpower for achieving better performance. I've been hyped about using Rust for Node.js native modules, but [my experience in practice has been full of obstacles](https://staltz.com/rust-for-mobile-not-yet.html). Now, I'm giving Zig a try. It can produce small binaries with great performance, it builds for all targets I can imagine (out of the box), and is overall a simple and approachable language built for the year 2021. It certainly feels like a young language, but let's test it out, I guess.
Expand Down

0 comments on commit f68ba98

Please sign in to comment.