![PyPI Now Supports iOS and Android Wheels for Mobile Python Development](https://cdn.sanity.io/images/cgdhsj6q/production/96416c872705517a6a65ad9646ce3e7caef623a0-1024x1024.webp?w=400&fit=max&auto=format)
Security News
PyPI Now Supports iOS and Android Wheels for Mobile Python Development
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Express middleware to map the great circle path between any two airports.
Gcpath is a Connect/Express middleware package that allows you to easily plot the flightpath between two airports on a static map in PNG-format.
It links up to simple formatted URLs with two IATA airport codes such as /map/BRU/YYZ
and calls the Mapbox static API to produce a map with markers on both sides and the great circle path between the two.
Gcpath can be use anywhere in your path structure but expects to receive two parameters named :from
and :to
that will contain upper case IATA codes when requested:
const express = require('express')
const app = express()
const gcpath = require('gcpath')
app.use('/map/:from/:to', gcpath({
token: '{Your Mapbox API token}'
}))
app.listen(3000, function() {
console.log('Listening on port 3000')
})
In this configuration, a call to /map/BRU/YYZ
will return a 512 by 512 pixel image of the shortest flightpath between Brussels Airport and Toronto Pearson airport. See below for details on how to change the size or the colour of images.
The gcpath function takes an object of options as the first and only parameter. Only one of these is required:
token
: Your personal Mapbox API-token. Check here to obtain one. (required)width
: Width of the image in pixels (default: 512)height
: Height of the image in pixels (default: 512)fromIcon
: Name of the Mapbox Maxi icon to use at the origin airport (default: 'airport')fromColour
: Background colour (in hex format) of the icon to use at the origin aiport (default: '#002850')toIcon
: Name of the Mapbox Maxi icon to use at the destination airport (default: 'airport')toColour
: Background colour (in hex format) of the icon to use at the destination aiport (default: '#002850')pathColour
: Stroke colour (in hex format) to use for the path between both airports (default: '#ff0006)MIT (c) 2018 Raphael Cockx (@raphaelcockx)
FAQs
Express middleware to map the great circle path between any two airports.
The npm package gcpath receives a total of 0 weekly downloads. As such, gcpath popularity was classified as not popular.
We found that gcpath demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.