Skip to content

CameronGu/data-snippets

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

14 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

data-snippets

A collection of useful JSON files, filters, and helper scripts β€” mostly related to travel (airports, countries, etc.), with a few handy utility functions mixed in. I put this together for personal projects but figured it might be useful to others too.


Contents

airports/

  • airports-full.original.json – Full global airport list
  • airports-trimmed.commercial.json – Trimmed list (just large & medium commercial airports with IATA codes)
  • trim-airports.js – Script to filter and simplify the full list
  • get-airport-flag.js – Adds a flag emoji to each airport based on country

countries/

  • country-phone-codes.original.json – Country names, dial codes, and flag emojis
  • country-emoji-map.generated.json – Just the emoji lookup (code β†’ emoji)
  • validate-country-emojis.js – Checks that the emoji generation function matches known flags

utils/

  • getFlagEmoji.ts – Converts ISO country codes to flag emojis (πŸ‡ΊπŸ‡Έ style)
  • mergeByKey.ts – Simple helper to join two arrays of objects on a shared key
  • debounce.ts – Lightweight debounce function for input fields

About Licensing

This repo pulls together data from a few public sources and contributors who shared their JSON freely online. I'm sharing it in the same spirit β€” feel free to use, adapt, or remix anything here.

That said, I can't guarantee the original licenses of every dataset, so if you're using it for anything serious or public-facing, double-check the source data and attribution as needed.


Purpose

Mostly just to save myself time. Now it’s all in one place β€” and if you find it useful too, awesome.

About

Reusable JSON files, utilities, and scripts for travel and dev projects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published