Skip to content

Commit

Permalink
Merge branch 'release/3.2.4' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
GhassenRjab committed Feb 4, 2021
2 parents 3a9f162 + 000b2e2 commit 9a813d3
Show file tree
Hide file tree
Showing 6 changed files with 1,841 additions and 686 deletions.
2 changes: 2 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@
/babel.config.json
/rollup.config.js
/.gitattributes
/MIGRATING.md
/CONTRIBUTING.md
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,18 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [3.2.4] - 2021-02-04

### Added [3.2.4]

- [48c8339](https://github.com/GhassenRjab/categorize/commit/48c8339) Write MIGRATING.md file ([@GhassenRjab](https://github.com/GhassenRjab))
- [264fb6f](https://github.com/GhassenRjab/categorize/commit/264fb6f) Write CONTRIBUTING.md file ([@GhassenRjab](https://github.com/GhassenRjab))

## [3.2.3] - 2020-12-20

### Changed [3.2.3]

- Don't ignore changelog in NPM package ([@GhassenRjab](https://github.com/GhassenRjab))
- [3d46bb5](https://github.com/GhassenRjab/categorize/commit/3d46bb5) Don't ignore changelog in NPM package ([@GhassenRjab](https://github.com/GhassenRjab))

## [3.2.2] - 2020-12-20

Expand Down
12 changes: 12 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Contribute to the project

Pull requests are welcome.

The project contains two main branches:

- `main`: contains the latest released code;
- `develop`: contains active development.

Branches for new futures should be created based on `develop` branch.

Branches for fixes should be created based on main `branch`.
31 changes: 31 additions & 0 deletions MIGRATING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Migration guides

## From v2 to v3

No migrations needed with this version. We just added `rollup` as build tool and added the browser build in our examples.

## From v1 to v2

The first version of `categorize` used `yup` to validate users' input. With this, the library had two ways to categorize arrays:

- a synchronous way using `categorizeSync` function;
- and an asynchronous way using `categorize` function.

With the second version, we removed `yup` library in order to become a zero-dependency library and did the validation manually.

With this change we only have one way to categorize which is the sychronous way. So we removed the `categorizeSync` function and changed the `categorize` function to become a synchronous one.

### Usage from v1

```js
// asynchronous way
const asyncResult = await categorize(animals, categories);
// synchronous way
const syncResult = categorizeSync(animals, categories);
```

### Usage from v2

```js
const result = categorize(animals, categories);
```
Loading

0 comments on commit 9a813d3

Please sign in to comment.