Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nurmdrafi/react-bkoi-gl
https://github.com/nurmdrafi/react-bkoi-gl
Last synced: 18 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/nurmdrafi/react-bkoi-gl
- Owner: nurmdrafi
- Created: 2024-09-10T05:38:55.000Z (3 months ago)
- Default Branch: master
- Last Pushed: 2024-09-11T10:19:45.000Z (3 months ago)
- Last Synced: 2024-09-12T09:39:38.645Z (3 months ago)
- Language: TypeScript
- Size: 325 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
react-bkoi-gl | Docs
## Description
`react-bkoi-gl` is a suite of [React](http://facebook.github.io/react/) components designed to provide a API for [Barikoi Maps](https://docs.barikoi.com/docs/maps-api). More information in the online documentation.
## Installation
Using `react-bkoi-gl` requires `react >= 16.3`.
To install the package via npm, run the following command:
```bash
npm install react-bkoi-gl
```
Or via yarn:
```bash
yarn add react-bkoi-gl
```### Example
```js
import { useRef } from 'react';
import { Map, FullscreenControl, GeolocateControl, NavigationControl, ScaleControl } from 'react-bkoi-gl';// Import Styles
import "react-bkoi-gl/styles"const App = () => {
const BARIKOI_API_KEY = 'YOUR_API_KEY'
const mapStyle = `https://map.barikoi.com/styles/osm-liberty/style.json?key=${BARIKOI_API_KEY}`
const mapContainer = useRef(null);
const mapRef = useRef(null);
const initialViewState = {
longitude: 90.36402,
latitude: 23.823731,
minZoom: 4,
maxZoom: 30,
zoom: 13,
bearing: 0,
pitch: 0,
antialias: true
}return (
)
}// JSX Styles
const containerStyles = {
width: "100%",
height: "100vh",
minHeight: "400px",
overflow: "hidden",
}export default App
```## Get Barikoi API key
To access Barikoi's API services, you need to:
1. Register on [Barikoi Developer Dashboard](https://developer.barikoi.com/register).
2. Verify with your phone number.
3. Claim your API key.Once registered, you'll be able to access the full suite of Barikoi API services. If you exceed the free usage limits, you'll need to subscribe to a paid plan.
## Learning Resources
* [Barikoi API Documentation](https://docs.barikoi.com/docs/maps-api)## License
This library is licensed under the MIT License. See the [LICENSE](https://www.npmjs.com/package/LICENSE) file for details.## Support
For any issues or questions, please contact [[email protected]](mailto:[email protected]).