Skip to content

Commit

Permalink
v5.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
bhousel committed Mar 12, 2023
1 parent be0e959 commit 55b6eb0
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 38 deletions.
47 changes: 27 additions & 20 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,35 @@
# What's New

**country-coder** is an open source project. You can submit bug reports, help out,
or learn more by visiting our project page on GitHub: :octocat: https://github.com/ideditor/country-coder
or learn more by visiting our project page on GitHub: :octocat: https://github.com/rapideditor/country-coder

Please star our project on GitHub to show your support! :star:
Please star our project on GitHub to show your support! ⭐️

_Breaking changes, which may affect downstream projects, are marked with a_ :warning:
_Breaking changes, which may affect downstream projects, are marked with a_ ⚠️


<!--
# A.B.C
##### YYYY-MMM-DD
*
[#xx]: https://github.com/ideditor/country-coder/issues/xx
[#xx]: https://github.com/rapideditor/country-coder/issues/xx
-->

# 5.2.0
##### 2023-Mar-12
* Bump dependency versions
* Switch country-coder to a scoped package under the rapideditor org: `@rapideditor/country-coder`
* ⚠️ Note: projects that depend on country-coder may need to update their code


# 5.1.0
##### 2022-Dec-09
* Close seam along Swiss-German border ([#61])
* Make Ireland less spiky ([#oci-528])
* Bump dependency versions

[#61]: https://github.com/ideditor/country-coder/issues/61
[#61]: https://github.com/rapideditor/country-coder/issues/61
[#oci-528]: https://github.com/osmlab/osm-community-index/issues/528


Expand All @@ -32,18 +39,18 @@ _Breaking changes, which may affect downstream projects, are marked with a_ :war
* Fix EU membership for France ([#47],[#55])
* Add GB-UKM for UK Mainland ([#52])

[#60]: https://github.com/ideditor/country-coder/issues/60
[#59]: https://github.com/ideditor/country-coder/issues/59
[#55]: https://github.com/ideditor/country-coder/issues/55
[#52]: https://github.com/ideditor/country-coder/issues/52
[#47]: https://github.com/ideditor/country-coder/issues/47
[#60]: https://github.com/rapideditor/country-coder/issues/60
[#59]: https://github.com/rapideditor/country-coder/issues/59
[#55]: https://github.com/rapideditor/country-coder/issues/55
[#52]: https://github.com/rapideditor/country-coder/issues/52
[#47]: https://github.com/rapideditor/country-coder/issues/47


# 5.0.3
##### 2021-Jun-24
* Remove "browser" from the export map ([#45])

[#45]: https://github.com/ideditor/country-coder/issues/45
[#45]: https://github.com/rapideditor/country-coder/issues/45


# 5.0.2
Expand All @@ -58,19 +65,19 @@ _Breaking changes, which may affect downstream projects, are marked with a_ :war

# 5.0.0
##### 2021-Jun-14
* :warning: Replace microbundle with [esbuild](https://esbuild.github.io/) for super fast build speed. Outputs are now:
* ⚠️ Replace microbundle with [esbuild](https://esbuild.github.io/) for super fast build speed. Outputs are now:
* `"source": "./src/country-coder.ts"` - TypeScript source file
* `"types": "./dist/country-coder.d.ts"` - TypeScript definition file
* `"main": "./dist/country-coder.cjs"` - CJS bundle, modern JavaScript, works with `require()`
* `"module": "./dist/country-coder.mjs"` - ESM bundle, modern JavaScript, works with `import`
* `"browser": "./dist/country-coder.iife.js"` - IIFE bundle, modern JavaScript, works in browser `<script>` tag
* Note: v4.1.0 was broken for some uses because of an improper "exports" specification ([#44])
* :warning: country-coder is marked as `"type": "module"` now
* :warning: Dropped support for old browsers like Internet Explorer on https://ideditor.codes
* ⚠️ country-coder is marked as `"type": "module"` now
* ⚠️ Dropped support for old browsers like Internet Explorer on https://ideditor.codes
* Use TypeScript / ts-jest for testing ([#43])

[#43]: https://github.com/ideditor/country-coder/issues/43
[#44]: https://github.com/ideditor/country-coder/issues/44
[#43]: https://github.com/rapideditor/country-coder/issues/43
[#44]: https://github.com/rapideditor/country-coder/issues/44


# 4.1.0
Expand All @@ -82,7 +89,7 @@ _Breaking changes, which may affect downstream projects, are marked with a_ :war
* Move Chukchi Peninsula from European Russia to Asian Russia ([#31])
* Support bbox querying ([#32])

[#12]: https://github.com/ideditor/country-coder/issues/12
[#15]: https://github.com/ideditor/country-coder/issues/15
[#31]: https://github.com/ideditor/country-coder/issues/31
[#32]: https://github.com/ideditor/country-coder/issues/32
[#12]: https://github.com/rapideditor/country-coder/issues/12
[#15]: https://github.com/rapideditor/country-coder/issues/15
[#31]: https://github.com/rapideditor/country-coder/issues/31
[#32]: https://github.com/rapideditor/country-coder/issues/32
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[![build](https://github.com/ideditor/country-coder/workflows/build/badge.svg)](https://github.com/ideditor/country-coder/actions?query=workflow%3A%22build%22)
[![npm version](https://badge.fury.io/js/%40ideditor%2Fcountry-coder.svg)](https://badge.fury.io/js/%40ideditor%2Fcountry-coder)
[![build](https://github.com/rapideditor/country-coder/workflows/build/badge.svg)](https://github.com/rapideditor/country-coder/actions?query=workflow%3A%22build%22)
[![npm version](https://badge.fury.io/js/%40rapideditor%2Fcountry-coder.svg)](https://badge.fury.io/js/%40rapideditor%2Fcountry-coder)

# country-coder

Expand Down Expand Up @@ -56,17 +56,17 @@ Client-side coding has a number of benefits over server-side solutions:

### Use in Node

`npm install @ideditor/country-coder`
`npm install @rapideditor/country-coder`

**country-coder** is distributed in CJS and ESM module formats for maxmimum compatibility. ([Read more about Javascript module formats](https://dev.to/iggredible/what-the-heck-are-cjs-amd-umd-and-esm-ikm))


```js
const countryCoder = require('@ideditor/country-coder'); // CommonJS import all
const iso1A2Code = require('@ideditor/country-coder').iso1A2Code; // CommonJS import named
const countryCoder = require('@rapideditor/country-coder'); // CommonJS import all
const iso1A2Code = require('@rapideditor/country-coder').iso1A2Code; // CommonJS import named
// or
import * as countryCoder from '@ideditor/country-coder'; // ESM import all
import { iso1A2Code } from '@ideditor/country-coder'; // ESM import named
import * as countryCoder from '@rapideditor/country-coder'; // ESM import all
import { iso1A2Code } from '@rapideditor/country-coder'; // ESM import named
```


Expand All @@ -77,7 +77,7 @@ You can also use **country-coder** directly in a web browser. A good way to do t
When you load this file in a `<script>` tag, you'll get a `countryCoder` global to use elsewhere in your scripts:
```html
<head>
<script src="https://cdn.jsdelivr.net/npm/@ideditor/[email protected]/dist/country-coder.iife.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/@rapideditor/[email protected]/dist/country-coder.iife.min.js"></script>
</head>
<script>
Expand Down Expand Up @@ -113,7 +113,7 @@ Read the [full API reference](#api-reference) to see everything `country-coder`

## Contributing

This package is kept intentionally minimal. However, if you find a bug or have an interesting idea for an enhancement, feel free to open an [Issue](https://github.com/ideditor/country-coder/issues) and/or [Pull Request](https://github.com/ideditor/country-coder/pulls).
This package is kept intentionally minimal. However, if you find a bug or have an interesting idea for an enhancement, feel free to open an [Issue](https://github.com/rapideditor/country-coder/issues) and/or [Pull Request](https://github.com/rapideditor/country-coder/pulls).


## API Reference
Expand Down
6 changes: 3 additions & 3 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no'/>
<script src='https://api.tiles.mapbox.com/mapbox-gl-js/v1.13.1/mapbox-gl.js'></script>
<script defer src='https://kit.fontawesome.com/c772610440.js' crossorigin='anonymous'></script>
<script defer src="https://cdn.jsdelivr.net/npm/@ideditor/[email protected]/dist/country-coder.iife.min.js"></script>
<script defer src="https://cdn.jsdelivr.net/npm/@rapideditor/[email protected]/dist/country-coder.iife.min.js"></script>
<!-- <script defer src='../dist/country-coder.iife.js'></script> -->
<link href='https://api.tiles.mapbox.com/mapbox-gl-js/v1.13.1/mapbox-gl.css' rel='stylesheet'/>
<link href='style.css' rel='stylesheet' type='text/css'/>
Expand Down Expand Up @@ -63,7 +63,7 @@
<div class='icon'><i class='fas fa-file-code fa-lg'></i></div>
</div>
<div id='octocat'>
<a href='https://github.com/ideditor/country-coder' target='_blank'>
<a href='https://github.com/rapideditor/country-coder' target='_blank'>
<i class='fab fa-github fa-2x'></i>
</a>
</div>
Expand Down Expand Up @@ -174,7 +174,7 @@

window.addEventListener('DOMContentLoaded', function(e) {
// Load the borders json
fetch('https://cdn.jsdelivr.net/gh/ideditor/country-coder@main/src/data/borders.json')
fetch('https://cdn.jsdelivr.net/gh/rapideditor/country-coder@main/src/data/borders.json')
.then(function(response) {
if (!response.ok) throw new Error(response.status + ' ' + response.statusText);
return response.json();
Expand Down
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "@ideditor/country-coder",
"version": "5.1.0",
"name": "@rapideditor/country-coder",
"version": "5.2.0",
"description": "Convert longitude-latitude pairs to ISO 3166-1 codes quickly and locally",
"repository": "github:ideditor/country-coder",
"repository": "github:rapideditor/country-coder",
"license": "ISC",
"keywords": [
"reverse geocoder",
Expand Down Expand Up @@ -31,10 +31,10 @@
"devDependencies": {
"@mapbox/geojson-rewind": "^0.5.2",
"@types/jest": "^29.4.0",
"@types/node": "^18.14.2",
"esbuild": "^0.17.10",
"@types/node": "^18.15.0",
"esbuild": "^0.17.11",
"esbuild-jest": "~0.5.0",
"jest": "^29.4.3",
"jest": "^29.5.0",
"jest-extended": "^3.2.4",
"npm-run-all": "^4.1.5",
"prettier": "^2.8.4",
Expand Down

0 comments on commit 55b6eb0

Please sign in to comment.