PHPackages                             siddthartha/geo-area - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. siddthartha/geo-area

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

siddthartha/geo-area
====================

Geographical area of given polygon in WGS84

1331PHP

Since May 3Pushed 2y ago1 watchersCompare

[ Source](https://github.com/siddthartha/geo-area-calculator)[ Packagist](https://packagist.org/packages/siddthartha/geo-area)[ RSS](/packages/siddthartha-geo-area/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (0)

geo-area-calculator
===================

[](#geo-area-calculator)

Calculation of polygon area in WGS'84 coordinates. Port of the Python algorithm to PHP and JS.

Install
=======

[](#install)

In the project root folder:

```
.../geo-area-calculator$ composer install
```

If js tests needed:

```
.../geo-area-calculator$ npm install
```

Tests
=====

[](#tests)

PHP
---

[](#php)

```
.../geo-area-calculator$ phpunit
```

JavaScript
----------

[](#javascript)

```
.../geo-area-calculator$ npm test
```

Examples
========

[](#examples)

JavaScript
----------

[](#javascript-1)

```
alert( ffGeo.getGeoPolygonArea(
			[
				[ -10.812317, 18 ],
				[ 10.812317, -18 ],
				[ 26.565051,  18 ],
				[ 52.622632, -18 ],
				[ 52.622632,  54 ],
				[ 10.812317,  54 ],
				[ -10.812317, 18 ],
			]
) );
```

PHP
---

[](#php-1)

```
use siddthartha\geo\area\helpers\GeoAreaCalculator;

echo GeoAreaCalculator::getArea(
        [
                [ -10.812317, 18 ],
                [ 10.812317, -18 ],
                [ 26.565051,  18 ],
                [ 52.622632, -18 ],
                [ 52.622632,  54 ],
                [ 10.812317,  54 ],
                [ -10.812317, 18 ],
        ]
);
// 33953235824742.51 (sq.meters)
```

###  Health Score

15

—

LowBetter than 3% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity19

Early-stage or recently created project

 Bus Factor1

Top contributor holds 97.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/627326?v=4)[Anton Sadovnikov](/maintainers/siddthartha)[@siddthartha](https://github.com/siddthartha)

---

Top Contributors

[![siddthartha](https://avatars.githubusercontent.com/u/627326?v=4)](https://github.com/siddthartha "siddthartha (45 commits)")[![romka-chev](https://avatars.githubusercontent.com/u/5673136?v=4)](https://github.com/romka-chev "romka-chev (1 commits)")

### Embed Badge

![Health badge](/badges/siddthartha-geo-area/health.svg)

```
[![Health](https://phpackages.com/badges/siddthartha-geo-area/health.svg)](https://phpackages.com/packages/siddthartha-geo-area)
```

###  Alternatives

[imi/magento2-store-switch-all-store-views

This module makes all store views available in the store switcher, regardless of their store or website.

1825.4k](/packages/imi-magento2-store-switch-all-store-views)[acelot/resolver

Dependency auto resolver for PHP 7 and 8

122.7k](/packages/acelot-resolver)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
