https://github.com/sharedstreets/sharedstreets-types
TypeScript definitions for SharedStreets.js
https://github.com/sharedstreets/sharedstreets-types
Last synced: about 1 year ago
JSON representation
TypeScript definitions for SharedStreets.js
- Host: GitHub
- URL: https://github.com/sharedstreets/sharedstreets-types
- Owner: sharedstreets
- License: mit
- Created: 2018-01-04T14:24:05.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-06-19T22:50:55.000Z (about 8 years ago)
- Last Synced: 2025-04-12T05:14:08.933Z (about 1 year ago)
- Language: TypeScript
- Homepage:
- Size: 48.8 KB
- Stars: 2
- Watchers: 5
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# TypeScript definitions for [SharedStreets.js](https://sharedstreets.io/)
[](https://badge.fury.io/js/sharedstreets-types)
[](https://travis-ci.org/sharedstreets/sharedstreets-types)
## Installation
```
npm install --save sharedstreets-types
```
## Example
```ts
import { SharedStreetsIntersection, RoadClass } from './'
// Intersection
const intersection: SharedStreetsIntersection = {
id: 'ABC',
nodeId: 123,
inboundReferenceIds: ['DEF'],
outboundReferenceIds: ['GHI']
}
// RoadClass
RoadClass.Motorway // => 0
RoadClass.Trunk // => 1
```
## Summary
This package contains type definitions for sharedstreets (https://sharedstreets.io/).
## Credits
These definitions were written by Denis Carriere https://github.com/DenisCarriere.