{"id":24906422,"url":"https://github.com/hazyvt/bunglfw","last_synced_at":"2025-10-16T18:30:49.093Z","repository":{"id":220167224,"uuid":"750182750","full_name":"HazyVT/BunGLFW","owner":"HazyVT","description":"Typescript bindings of GLFW made for bun","archived":false,"fork":false,"pushed_at":"2024-02-08T08:57:58.000Z","size":176,"stargazers_count":16,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-02-08T09:51:56.401Z","etag":null,"topics":["bun","bunsh","glfw","glfw-bindings","glfw3","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/HazyVT.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2024-01-30T06:25:09.000Z","updated_at":"2024-02-06T18:43:02.000Z","dependencies_parsed_at":"2024-02-08T09:42:39.776Z","dependency_job_id":null,"html_url":"https://github.com/HazyVT/BunGLFW","commit_stats":null,"previous_names":["hazyvt/bunglfw"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HazyVT%2FBunGLFW","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HazyVT%2FBunGLFW/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HazyVT%2FBunGLFW/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HazyVT%2FBunGLFW/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HazyVT","download_url":"https://codeload.github.com/HazyVT/BunGLFW/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":236738643,"owners_count":19196962,"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":["bun","bunsh","glfw","glfw-bindings","glfw3","typescript"],"created_at":"2025-02-02T00:40:19.526Z","updated_at":"2025-10-16T18:30:48.742Z","avatar_url":"https://github.com/HazyVT.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BunGLFW\n\nTypescript bindings for bun. No installation needed.\n\nTo install please use \n```node\nbun install bunglfw\n```\n\nHere is an example of some code\n\n```ts\nimport { \n  glfwSetKeyCallback, \n  GLFW_FALSE, \n  GLFW_MAXIMIZED, \n  GLFW_RESIZABLE, \n  GLFW_TRUE, \n  GLFW_VISIBLE, \n  glfwCreateWindow, \n  glfwInit, \n  glfwMakeContextCurrent, \n  glfwPollEvents, \n  glfwSetErrorCallback, \n  glfwShowWindow, \n  glfwSwapBuffers, \n  glfwSwapInterval, \n  glfwWindowHint, \n  glfwWindowShouldClose,  \n  GLFW_PRESS, \n  GLFW_KEY_ESCAPE, \n  glfwSetWindowShouldClose, \n  glfw_error_codes, \n  glfwDefaultWindowHints, \n  type GLFWkeyfun, type glfwWindow, \n} from \"bunglfw\";\n\nif (!glfwInit()) {\n  throw new Error(\"GLFW Failed to initialize\");\n}\n\nconst error_call = (error_code: number, description: string) =\u003e {\n  [...glfw_error_codes.keys()].forEach((key) =\u003e {\n    if (glfw_error_codes.get(key) == error_code) {\n      console.error(key);\n    }\n  })\n}\n\nlet controls: GLFWkeyfun = (window: glfwWindow, key: number, scancode: number, action: number, mods: number) =\u003e {\n  if (action == GLFW_PRESS) {\n    if (key == GLFW_KEY_ESCAPE) {\n      glfwSetWindowShouldClose(window, GLFW_TRUE);\n    }\n  }\n}\n\nglfwDefaultWindowHints();\nglfwWindowHint(GLFW_VISIBLE, GLFW_FALSE);\nglfwWindowHint(GLFW_RESIZABLE, GLFW_FALSE);\nglfwWindowHint(GLFW_MAXIMIZED, GLFW_TRUE);\n\nconst window = glfwCreateWindow(640, 480, \"Hello World\", null, null);\n\n\nglfwSetKeyCallback(window, controls)\nglfwSetErrorCallback(error_call);\n\nglfwMakeContextCurrent(window);\n\nglfwSwapInterval(1);\nglfwShowWindow(window);\n\nwhile (!glfwWindowShouldClose(window)) {\n  glfwPollEvents();\n\n  glfwSwapBuffers(window);\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhazyvt%2Fbunglfw","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhazyvt%2Fbunglfw","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhazyvt%2Fbunglfw/lists"}