
Security News
MCP Community Begins Work on Official MCP Metaregistry
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
@freenow/react-polygon-editor
Advanced tools
A react component for displaying and drawing geo polygons
React Polygon Editor provides react components for displaying and editing polygons. We use leaflet for rendering maps. And typescript to provide a strongly typed interface.
First install @freenow/react-polygon-editor:
npm i -S @freenow/react-polygon-editor
Make sure you have also installed all peer dependencies. Have a look at package.json for more information.
npm i -S react react-dom react-leaflet leaflet styled-components
inject the leaflet css style.
Import 'leaflet/dist/leaflet.css';
You can also link the css style from a CDN in your index.html
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.4.0/dist/leaflet.css" />
Props
The initialCenter and initialZoom props are applicable only when both the polygon and the boundary coordinates are empty. This flow explains which parameters are used to focus the map:
For more details, have a look at the Component definition in PolygonDraw
You can run the library locally. We use storybook to illustrate what can be done with the components.
Simply run:
npm i && npm start
[1.1.0] - 12.03.2020
FAQs
A react component for displaying and drawing geo polygons
The npm package @freenow/react-polygon-editor receives a total of 12 weekly downloads. As such, @freenow/react-polygon-editor popularity was classified as not popular.
We found that @freenow/react-polygon-editor demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 9 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
Research
Security News
Socket uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
Research
Security News
Malicious npm packages posing as developer tools target macOS Cursor IDE users, stealing credentials and modifying files to gain persistent backdoor access.