farmOS / farmOS-map

farmOS-map is an OpenLayers wrapper library designed for agricultural mapping needs. It can be used in any project that has similar requirements.
https://farmOS.github.io/farmOS-map
MIT License
40 stars 22 forks source link

Publish to NPM #64

Closed mstenta closed 3 years ago

mstenta commented 4 years ago

Should we publish farmOS-map to NPM?

mstenta commented 4 years ago

@jgaehring made the point that we might need to rename from farmOS-map to farmos-map in package.json.

jgaehring commented 4 years ago

The main benefits I can come up with at the moment are that it would make the library:

So I guess the first question is, do we want to prioritize discovery of this library?

My sense at this time is that, no, that is not a priority. This library would be useful to other developers I think only at the point that they are consuming other libraries first, like farmOS.js etc, and potentially farmLog (if we make that an independent lib), because until they are able to access and maintain farmOS data, particularly farm geometries and location data, there won't be a need for rendering that data to a map. Maybe if someday we want to put together a farmOS SDK this would be a key component, but I don't think that's on our roadmap at the moment.

jgaehring commented 4 years ago

@jgaehring made the point that we might need to rename from farmOS-map to farmos-map in package.json.

:scream:

mstenta commented 4 years ago

This library would be useful to other developers I think only at the point that they are consuming other libraries first

Our Sci is considering using the library in their PWA and potentially in their Quick Carbon app. The latter does not have any direct connection to farmOS. Just to say that there are some potential use-cases developing... but they can also just do what farmOS-client is doing in package.json and reference the GitHub repo directly with "farmOS-map": "github:farmOS/farmOS-map#v1.0.0".

jgaehring commented 4 years ago

Just to say that there are some potential use-cases developing

Oh interesting, not sure I realized that. I guess I'm wondering whether we want to capture third-party developers who might not otherwise be aware it was an option. Folks we're not already working with, or might not ever have a close connection to.

mstenta commented 3 years ago

Bumping up the priority of this. We need to be able to pull farmOS-map from NPM (or Bower) in order to include it in farmOS 2.x via Composer. These needs are described in: https://www.drupal.org/project/farm/issues/3186641

mstenta commented 3 years ago

Done!

https://www.npmjs.com/package/@farmos.org/farmos-map

And available on asset-packagist.org:

https://asset-packagist.org/package/detail?fullname=npm-asset/farmos.org--farmos-map

Encountered an issue in the process, and implemented a workaround, which I documented here: https://github.com/farmOS/farmOS-map/issues/99