From e5f6d0f732177bb939c9ed759c017360ac147748 Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Mon, 25 Jul 2016 21:56:58 -0400 Subject: [PATCH] Add Simple Examples KISS --- README.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 5b90315..6d2cd6a 100644 --- a/README.md +++ b/README.md @@ -3,8 +3,17 @@ s2-geometry-javascript Porting Google's S2 Geometry Library to Javascript - Currently contains basic support for S2Cell -More details and examples to come later. +Simple Examples +--------------- +```javascript +var cell = S2.S2Cell.FromLatLng({ lat: 40.2574448, lng: -111.7089464 }, 15); + +cell.getNeighbors(); // [ cellLeft, cellDown, cellRight, cellUp ] + +cell.getLatLng(); // { lat: 40.2574448, lng: -111.7089464 } +``` + +More details and examples to come later.