From 163c7d029dd397e5e027e1491ec946510bab1ce6 Mon Sep 17 00:00:00 2001 From: Jonas Berlin Date: Sat, 18 Feb 2017 01:09:05 +0200 Subject: [PATCH] README: Add OpenLayers example config --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 46c4b46..5b2e9eb 100644 --- a/README.md +++ b/README.md @@ -9,3 +9,11 @@ First, just create an mbtiles file (via Tilemill probably cause it's freaking am 1. `node server.js TILEFILE [PORT]` Visit [http://localhost:3000/3/1/2.png](http://localhost:3000/3/1/2.png) + +In case you are using OpenLayers for rendering, you can use the following source config in your ol.Map({}) options: + +```js + source: new ol.source.TileImage({ + url:"http://localhost:3000/{z}/{x}/{y}.png" + }) +```