https://github.com/yaanno/deno-country-code
A fun little experiment with Deno and Typescript to convert ISO country codes
https://github.com/yaanno/deno-country-code
deno typescript
Last synced: about 1 month ago
JSON representation
A fun little experiment with Deno and Typescript to convert ISO country codes
- Host: GitHub
- URL: https://github.com/yaanno/deno-country-code
- Owner: yaanno
- Created: 2022-09-03T14:17:36.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-09-03T14:24:04.000Z (almost 4 years ago)
- Last Synced: 2025-01-14T13:13:56.887Z (over 1 year ago)
- Topics: deno, typescript
- Language: TypeScript
- Homepage:
- Size: 65.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# deno-country-code
A fun little experiment with [Deno](https://deno.land/) and Typescript slightly based on the [iso3166-1](https://github.com/moimikey/iso3166-1) library - Hey, Mike :)
The original idea was to compile the code to Wasm and awe the exec speed in the browser (and other Wasm capable environments). Alas, the [Assemblyscript](https://www.assemblyscript.org/) compiler did not like my code so far.
The code won't work out of the box with Node.js as it needs a bunch of libraries and setup and eff that, Deno does that by default (and fast!).
See `index.ts` for examples.
Run the converter (strip down the json to iso codes only):
```sh
deno run --allow-write convert.ts
```
Run the examples:
```sh
deno run index.ts
```