# fhirmapping

> Describes the implementation of FHIR Mapping Language. It is necessary to trnasfer FHIR resources from one version of FHIR standart to another.

Latest version **1.0.0** (published 2019-06-19) · ISC license · 0 weekly downloads

## Install

```sh
npm install fhirmapping
pnpm add fhirmapping
yarn add fhirmapping
bun add fhirmapping
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2019-06-19 |
| First published | 2019-06-19 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 33.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Aleksei Chistiakov |
| Maintainers | krayzex |

## Links

- npm: https://www.npmjs.com/package/fhirmapping
- npm.io page: https://npm.io/package/fhirmapping

## Dependencies (3)

- [chai](https://npm.io/package/chai.md) ^4.2.0
- [set-deep](https://npm.io/package/set-deep.md) ^0.1.1
- [object-path](https://npm.io/package/object-path.md) ^0.11.4

## Recent versions

- 1.0.0 (latest) — 2019-06-19

## README

# FHIR Mapping Language
Describes the implementation of FHIR Mapping Language. It is necessary to trnasfer FHIR resources from one version of FHIR standart to another.

## The main part of implementation is mappingEngine.js
The engine works automatically. It receives a transformation map as input and applies it to the old version of the resource.

The code snippet is shown below.

```
//JavaScript code

        switch(operation){
        case 'move':
            setElement(newPathFromMap, saveResource, elementFromPath);
            deepDelete(oldPathFromMap, saveResource);
            break;
        case 'add':
            setElement(newPathFromMap, saveResource, {});
            break;
        default:
            new Error('Operations are not find!');
        }
    }

```
## How it works
Example

![Снимок экрана от 2019-06-19 13-59-58](https://user-images.githubusercontent.com/25884047/59760278-9a214000-929a-11e9-927a-032675b1a981.png)

---
_Source: https://npm.io/package/fhirmapping · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
