{"id":28070161,"url":"https://github.com/geoarrow/geoarrow-js","last_synced_at":"2025-05-12T19:38:43.397Z","repository":{"id":208502126,"uuid":"721774832","full_name":"geoarrow/geoarrow-js","owner":"geoarrow","description":"TypeScript implementation of GeoArrow","archived":false,"fork":false,"pushed_at":"2025-02-10T19:21:39.000Z","size":315,"stargazers_count":28,"open_issues_count":5,"forks_count":6,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-15T04:18:56.418Z","etag":null,"topics":["apache-arrow","geoarrow","typescript"],"latest_commit_sha":null,"homepage":"http://geoarrow.org/geoarrow-js/","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/geoarrow.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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,"publiccode":null,"codemeta":null}},"created_at":"2023-11-21T18:44:34.000Z","updated_at":"2025-03-15T19:04:40.000Z","dependencies_parsed_at":"2024-06-24T21:23:18.995Z","dependency_job_id":"4aa2a2b3-6321-4305-8b7b-794decb5175e","html_url":"https://github.com/geoarrow/geoarrow-js","commit_stats":null,"previous_names":["geoarrow/geoarrow-js"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geoarrow%2Fgeoarrow-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geoarrow%2Fgeoarrow-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geoarrow%2Fgeoarrow-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geoarrow%2Fgeoarrow-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/geoarrow","download_url":"https://codeload.github.com/geoarrow/geoarrow-js/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253808971,"owners_count":21967634,"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":["apache-arrow","geoarrow","typescript"],"created_at":"2025-05-12T19:38:42.878Z","updated_at":"2025-05-12T19:38:43.388Z","avatar_url":"https://github.com/geoarrow.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `geoarrow-js`\n\nA minimal TypeScript implementation of [GeoArrow](https://geoarrow.org/) building on top of [Arrow JS](https://arrow.apache.org/docs/js/index.html).\n\nIt complements the work-in-progress [`geoarrow-wasm`](https://github.com/geoarrow/geoarrow-rs/tree/main/js), which will provide Rust-based operations on GeoArrow memory.\n\n## Features\n\n- Performant spatial operations.\n- Rich static typing of geometry arrays.\n- Tree shakeable.\n- Utilities for sharing Arrow data across Web Workers (not specific to GeoArrow)\n\n## Spatial operations\n\nOnly spatial operations that are implemented on binary representations of geometry will be added to this repo.\n\nThis means that `geoarrow-js` will not, say, use algorithms from [Turf](https://turfjs.org/), because that would require conversions to and from GeoJSON for the operation.\n\n### Implemented algorithms:\n\nRefer to the [`algorithm` namespace](https://geoarrow.github.io/geoarrow-js/modules/algorithm.html) in the docs.\n\n- Polygon area and signed area (via [`@math.gl/polygon`](https://github.com/visgl/math.gl))\n- Polygon winding order (via [`@math.gl/polygon`](https://github.com/visgl/math.gl))\n- Polygon triangulation (via [`@math.gl/polygon`](https://github.com/visgl/math.gl), a fork of [`earcut`](https://github.com/mapbox/earcut).)\n- Coordinate reprojection (via [`proj4`](https://github.com/proj4js/proj4js))\n- Total bounds (the bounding box of an array of geometries).\n\n## Web Worker utilities\n\nRefer to the [`worker` namespace](https://geoarrow.github.io/geoarrow-js/modules/worker.html). Use `preparePostMessage` to obtain references to all underlying `ArrayBuffer` objects, so they can be transfered instead of copied.\n\n```ts\nimport * as arrow from \"apache-arrow\";\nimport {\n  preparePostMessage,\n  rehydrateVector,\n} from \"@geoarrow/geoarrow-js/worker\";\n\nconst originalVector = arrow.makeVector(new Int32Array([1, 2, 3]));\nconst [preparedVector, arrayBuffers] = preparePostMessage(originalVector);\n\n// Here we use structuredClone to simulate a postMessage but on the main thread\nconst receivedVector = structuredClone(preparedVector, {\n  transfer: arrayBuffers,\n});\nconst rehydratedVector = rehydrateVector(receivedVector);\n```\n\n## Ecosystem\n\n`geoarrow-js` is designed to be used seamlessly with WebAssembly-based GeoArrow operations, such as those in the JavaScript bindings of the Rust GeoArrow implementation, and with rendering libraries, such as [deck.gl](https://deck.gl/), with the help of [`@geoarrow/deck.gl-layers`](https://github.com/geoarrow/deck.gl-layers).\n\nFor more background on my plans for GeoArrow ecosystem in JS and WebAssembly, refer to [this thread](https://github.com/geoarrow/geoarrow-rs/issues/283).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeoarrow%2Fgeoarrow-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgeoarrow%2Fgeoarrow-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeoarrow%2Fgeoarrow-js/lists"}