@jezpoz/react-openlayers
TypeScript icon, indicating that this package has built-in type declarations

0.0.1 • Public • Published

React Openlayers

⚠️ This is still work in progress: Very limited functionality!

Repo heavily inspired by react-openlayers made by Allen Kim

Usage

import { Map, Layers } from "react-overlays";
import TileLayer from "ol/layer/Tile";
import OSM from "ol/source/OSM";
import View from "ol/View";

export default function App() {
  const view = new View({ center: [0, 0], zoom: 2 });
  const layer = new TileLayer({
    source: new OSM(),
  });

  return (
    <Map view={view} width={"100%"} height={"600px"}>
      <Layers.Tile layer={layer} />
    </Map>
  );
}

Wanna test it out?

Feel free to clone the repository, if there is any issues, feel free to report them here

git clone https://github.com/jezpoz/react-openlayers
cd react-openlayers
npm i
npm run dev

Readme

Keywords

Package Sidebar

Install

npm i @jezpoz/react-openlayers

Weekly Downloads

1

Version

0.0.1

License

MIT

Unpacked Size

586 kB

Total Files

36

Last publish

Collaborators

  • jezpoz