1.4.0 • Published 4 years ago

neptunus v1.4.0

Weekly downloads
14
License
MIT
Repository
github
Last release
4 years ago

neptunus

Make your GPX files match trails easily.

Installing

Using npm:

$ npm install neptunus

Using yarn:

$ yarn add neptunus

Launching

Import the module

You could import the module using import syntax.

import Neptunus from 'neptunus'

Or using require syntax.

const Neptunus = require('neptunus').default

Creating an instance

You have to create a new instance of neptunus with a mapbox access token.

const instance = new Neptunus({ mapboxAccessToken: 'YOUR_MAPBOX_TOKEN_HERE' })

Neptunus.match(path)

Then, open a GPX file and pass it to neptunus as a string.

const file = await readFile('./assets/thabor.gpx', 'utf-8')
const output = await instance.match(file.toString())

Promises

neptunus depends on a native ES6 Promise implementation to be supported. If your environment doesn't support ES6 Promises, you can polyfill.

TypeScript

neptunus includes TypeScript definitions.

License

MIT

1.4.0

4 years ago

1.1.0

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago