npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

damascus

v1.4.0

Published

Hierarchical source of truth for Syrian regional data, focusing on Damascus municipalities and neighborhoods aligned with UN OCHA standards.

Readme

Damascus (Syrian Regional Data API)

Build Status MIT License Semantic release Damascus package Coverage Status

The ultimate environment-agnostic source of truth for Syrian administrative data.

This package provides a meticulously standardized, deeply hierarchical dataset covering all of Syria (Governorates ➔ Districts ➔ Municipalities ➔ Neighborhoods/Populated Places).

It is completely aligned with UN OCHA Common Operational Datasets (COD), featuring official P-Codes and geo-spatial coordinates. It's the perfect backbone for cascading dropdowns, map plots, and autocompletes in applications like real estate listings, directories, and delivery platforms.

Installation

This package is distributed via npm:

npm install damascus

Usage (Core API)

Modern projects should import the package via ES Modules. Full TypeScript definitions (.d.ts) are included natively for excellent IDE support.

import { search, getAll, getGovernorates, getDistricts, getMunicipalities, getNeighborhoods } from 'damascus';

// 1. Search API (Perfect for Autocomplete)
const result = search('دمشق');

// 2. Get the 14 Syrian governorates
const governorates = getGovernorates();
/* 
[
  { 
    id: 'dam', 
    pcode: 'SY01', 
    coordinates: { lat: 33.5138, lng: 36.2765 },
    name: { en: 'Damascus', ar: 'دمشق' } 
  },
  ...
]
*/

// 3. Drill down into the unified hierarchy
const damascusDistricts = getDistricts('dam'); 
const municipalities = getMunicipalities('dam-damascus'); 
const neighborhoods = getNeighborhoods('dam-municipality-ancient-city-old-city');

Usage (React Hooks)

To eliminate boilerplate when building cascading dropdowns, we provide highly-optimized React hooks out of the box!

import { useGovernorates, useDistricts, useMunicipalities } from 'damascus/react';
import { useState } from 'react';

function LocationSelector() {
  const [govId, setGovId] = useState('dam');
  const [distId, setDistId] = useState('dam-damascus');

  const governorates = useGovernorates();
  const districts = useDistricts(govId); // Automatically reacts to govId changes!
  const municipalities = useMunicipalities(distId);

  return (
    // Render your dropdowns...
  )
}

Features

  • Whole of Syria Coverage: Includes massive generated datasets for all 14 governorates down to populated places.
  • UN OCHA P-Codes: Built-in standard pcode identifiers for reliable cross-dataset interoperability.
  • Geo-Spatial Coordinates: Every level includes precise { lat, lng } coordinates.
  • React Hooks included: Exported via damascus/react for instant UI integration.
  • Search Utility: Built-in search function to easily query the deep data tree.
  • Bilingual: All items include English (en) and Arabic (ar) names.
  • TypeScript Support: First-class types mapping the entire hierarchy.

Other

This library was developed by Abdulhadi Hawari as a PoC to learn semantic-release, and expanded to be a robust source of truth for Syrian regional data.