lrsxcd / vip-repl

Clojure View-Interact-Pull REPL
1 stars 0 forks source link

Design the API functions #10

Open davidvoler opened 5 years ago

davidvoler commented 5 years ago

As leaflet is already working on the client side, we can take the time and design an API function to create a map. Maybe we can learn from R example what at the parameter of the function. we can also ad the magic we found there (creating automatic elements from data) Alternatively, we can look at leafletjs and decide what do we want to implement. We should start thinking of that data atom for the map that should be created as part of the call.

something like (def create-vip-repl-map[center zoom elements data] ;; )

amitramon commented 5 years ago

Pushed 1st revision.

Please note that any function that takes coordinates as argument (directly or via a map) expects them to be floating point (explicitly; i.e., an integer would raise an error).

Also, coordinate values printed inside HTML snippets have a precision of 8 decimal digits. Verify that this is okay.

Last but not least, the create-filter function is incomplete and probably not completely defined.