{"id":18417686,"url":"https://github.com/danieljdufour/geo-extent","last_synced_at":"2025-04-07T12:32:49.139Z","repository":{"id":48186819,"uuid":"393717001","full_name":"DanielJDufour/geo-extent","owner":"DanielJDufour","description":"Makes working with GeoSpatial Extents Easy.  A simple chainable extent class.","archived":false,"fork":false,"pushed_at":"2024-01-16T23:42:58.000Z","size":224,"stargazers_count":14,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-22T18:42:27.859Z","etag":null,"topics":["bbox","extent","geospatial","gis","javascript"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc0-1.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DanielJDufour.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,"publiccode":null,"codemeta":null}},"created_at":"2021-08-07T15:13:43.000Z","updated_at":"2024-03-13T23:06:23.000Z","dependencies_parsed_at":"2024-06-18T22:20:44.741Z","dependency_job_id":"df2a5512-55d9-45fb-a32c-13af7255dc5c","html_url":"https://github.com/DanielJDufour/geo-extent","commit_stats":{"total_commits":135,"total_committers":1,"mean_commits":135.0,"dds":0.0,"last_synced_commit":"2aa25592ab4b2c7da38eb6ad3df0e9120dddbc50"},"previous_names":[],"tags_count":36,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielJDufour%2Fgeo-extent","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielJDufour%2Fgeo-extent/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielJDufour%2Fgeo-extent/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielJDufour%2Fgeo-extent/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DanielJDufour","download_url":"https://codeload.github.com/DanielJDufour/geo-extent/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247653358,"owners_count":20973813,"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":["bbox","extent","geospatial","gis","javascript"],"created_at":"2024-11-06T04:10:49.939Z","updated_at":"2025-04-07T12:32:46.459Z","avatar_url":"https://github.com/DanielJDufour.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# geo-extent\n\u003e Simple, Modern Geospatial Bounding Boxes\n\n# features\n- immutable: all functions return a new GeoExtent\n- chainable: ex: `extent.reproj(3857).crop(other).toGeoJSON()`\n- universal input: works with bbox arrays, xy corner points, and Leaflet bounds\n- interoperability: integrates well with Leaflet, OpenLayers, and ESRI\n- precise: avoids some common floating-point arithmetic issues by using [preciso](https://github.com/danieljdufour/preciso)\n- typescript: includes type definitions\n\n# install\n```bash\nnpm install geo-extent\n```\n\n# basic usage\n```js\nimport { GeoExtent } from 'geo-extent';\n\n// extent of web mercator tile for x=964, y=1704, and z=12\nconst tile = new GeoExtent([-10605790.548624776, 3355891.2898323783, -10596006.609004272, 3365675.2294528796], { srs: 3857 });\n\n// convert tile extent to Latitude/Longitude\nconst latLngBBox = tile.reproj(4326).bbox;\n// latLngBBox is [-95.27343750000001, 28.84467368077178, -95.185546875, 28.921631282421277]\n\n// extent of a Cloud-Optimized GeoTIFF (COG) in UTM Projection 32615\nconst cog = new GeoExtent([259537.6, 3195976.8000000003, 281663.2, 3217617.6], { srs: 32615 });\n\n// partial is the part of the tile that overlaps the extent of the COG\nconst partial = tile.crop(cog);\n// partial is equivalent to GeoExtent([-10605790.548624776, 3358990.12945602, -10601914.152717294, 3365675.2294528796], 3857);\n```\n\n# documentation\nFor more functions and examples, please consult the documentation at https://github.com/DanielJDufour/geo-extent/tree/main/docs\n\n# used by \n- [GeoRasterLayer for Leaflet](https://github.com/GeoTIFF/georaster-layer-for-leaflet)\n \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanieljdufour%2Fgeo-extent","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanieljdufour%2Fgeo-extent","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanieljdufour%2Fgeo-extent/lists"}