{"id":15392646,"url":"https://github.com/jackdbd/zig-bolognajs","last_synced_at":"2026-01-06T17:35:40.670Z","repository":{"id":199132145,"uuid":"702201111","full_name":"jackdbd/zig-bolognajs","owner":"jackdbd","description":null,"archived":false,"fork":false,"pushed_at":"2024-01-11T02:38:23.000Z","size":14492,"stargazers_count":1,"open_issues_count":3,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-02T01:43:37.403Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://zig-bolognajs.vercel.app","language":"Vue","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jackdbd.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-10-08T19:30:33.000Z","updated_at":"2024-03-20T13:37:44.000Z","dependencies_parsed_at":"2023-10-16T19:49:30.311Z","dependency_job_id":"b2fd0666-af6f-476a-a0e3-43774032e383","html_url":"https://github.com/jackdbd/zig-bolognajs","commit_stats":{"total_commits":32,"total_committers":1,"mean_commits":32.0,"dds":0.0,"last_synced_commit":"0b3f2873237407633820899ec971a2b597480a65"},"previous_names":["jackdbd/zig-bolognajs"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackdbd%2Fzig-bolognajs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackdbd%2Fzig-bolognajs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackdbd%2Fzig-bolognajs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackdbd%2Fzig-bolognajs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jackdbd","download_url":"https://codeload.github.com/jackdbd/zig-bolognajs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245944062,"owners_count":20697948,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-01T15:15:28.197Z","updated_at":"2026-01-06T17:35:40.622Z","avatar_url":"https://github.com/jackdbd.png","language":"Vue","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Zig talk @ Bologna JS\n\nSlides and code for [my talk on Zig at Bologna JS](https://www.meetup.com/it-IT/bologna-js-meetup/events/296655951/).\n\nI gave a [similar presentation at pisa.dev](https://github.com/jackdbd/zig-tour). That presentation was more focused on the Zig C-interop, this presentation focuses on how to use Zig in a JS project. Moe precisely, in this presentation I talked about:\n\n1. Why Zig might be interesting for a JS developer. And why it could more interesting than other compiled languages (e.g. C, C++, Rust).\n2. Features that Zig decides to leave out of the language, and why.\n3. Building a project: JS vs Zig.\n4. Error handling: JS vs Zig.\n5. How to develop hybrid JS/Zig projects (for the browser, Node.js, and for other runtimes).\n6. How to use Zig libraries, and the Zig package manager.\n\nThe presentation is available online: https://zig-bolognajs.vercel.app/\n\nIn alternative, you can download the slides as a PDF: https://raw.githubusercontent.com/jackdbd/zig-bolognajs/main/assets/zig-bolognajs.pdf\n\nIf you want to run the presentation locally or modify it, follow the instructions below.\n\n## Installation\n\nThis presentation is a Vue.js application built with [Slidev](https://sli.dev/). You can install its dependencies with the following command:\n\n```sh\nnpm install\n```\n\n## Development\n\nSlidev can hot-code reload this presentation thanks to Vite. Zig [cannot yet do it](https://github.com/ziglang/zig/issues/68), but as a workaround we can list all zig source files and use [entr](https://github.com/eradman/entr) to watch them for changes.\n\nLaunch the Vite dev server and re-compile all WebAssembly modules with this command:\n\n```sh\nnpm run dev\n```\n\nYou can now view the presentation on localhost:\n\n- Play mode: http://localhost:3030/1\n- [Presenter](https://sli.dev/guide/presenter-mode.html) mode: http://localhost:3030/presenter/1\n\n## Deploy\n\nThe presentation will be automatically deployed to Vercel on each `git push`.\n\n\u003e :information_source: Since the zig compiler is not available on Vercel, and since I don't want to download it on each deployment, I rely on a pre-push git hook to build all WebAssembly modules locally. All files that end up in `public/` will be hosted as static files on Vercel. I'm not sure whether it is possible to push the `.wasm` modules to Vercel without tracking them in git. I tried to ignore them in the `.gitignore` and unignore them in the `.vercelignore`, but that didn't work.\n\n## PDF export\n\nSlidev allows [exporting the slides to a PDF](https://sli.dev/guide/exporting.html#pdf). This feature relies on [Playwright](https://playwright.dev/) and requires [playwright-chromium](https://www.npmjs.com/package/playwright-chromium) to be available.\n\n\u003e :information_source: Since I don't want to install Playwright when building on Vercel (so deployments are faster), I declare `playwright-chromium` as a dev dependency and set `npm install --omit=dev` as the Vercel `installCommand` in `vercel.json`.\n\nRun this command to export the presentation to `assets/zig-bolognajs.pdf` and the notes to `assets/zig-bolognajs-notes.pdf`.\n\n```sh\nnpm run build:pdf\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjackdbd%2Fzig-bolognajs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjackdbd%2Fzig-bolognajs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjackdbd%2Fzig-bolognajs/lists"}