
Product
Announcing Socket Certified Patches: One-Click Fixes for Vulnerable Dependencies
A safer, faster way to eliminate vulnerabilities without updating dependencies
@etalab/gazetteer
Advanced tools
Bibliothèque permettant de déterminer le découpage administratif dans lequel se trouve des coordonnées géographiques au format WGS-84.
Données fournies :
| Niveau administratif | Source | Géométrie |
|---|---|---|
| Région | INSEE/COG | dérivée d'ADMIN EXPRESS |
| Département | INSEE/COG | dérivée d'ADMIN EXPRESS |
| EPCI | DGCL | dérivée d'ADMIN EXPRESS |
| Commune | INSEE/COG | dérivée d'ADMIN EXPRESS |
| Communes anciennes | INSEE/COG | OSM |
NB : Les géométries des collectivités d'outremer proviennent d'OSM.
⚠️ Le chemin d’accès aux données doit être renseigné, soit via le paramètre dbPath, soit via la variable d’environnement GAZETTEER_DB_PATH.
const {createGazetteer} = require('@etalab/gazetteer')
const g = await createGazetteer(options)
await g.find({lon: 5.9225, lat: 49.2741})
>
{
communeAncienne: { nom: 'Mance', code: '54341' },
commune: { nom: 'Val de Briey', code: '54099' },
epci: { nom: 'CC Orne Lorraine Confluences', code: '200070845' },
arrondissement: { nom: 'Briey', code: '541' },
departement: { nom: 'Meurthe-et-Moselle', code: '54' },
region: { nom: 'Grand Est', code: '44' }
}
await g.find({lon: 0, lat: 0})
>
null
On clone le dépôt puis on installe les dépendances.
yarn
On lance la commande dédiée à la production des données.
yarn build
Le fichier résultant gazetteer.sqlite servira ensuite à utiliser la bibliothèque en elle-même.
MIT
FAQs
Lightweight gazetteer for France 🇫🇷
We found that @etalab/gazetteer demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
A safer, faster way to eliminate vulnerabilities without updating dependencies

Product
Reachability analysis for Ruby is now in beta, helping teams identify which vulnerabilities are truly exploitable in their applications.

Research
/Security News
Malicious npm packages use Adspect cloaking and fake CAPTCHAs to fingerprint visitors and redirect victims to crypto-themed scam sites.