The demo of compilation with library in a different ways.
This commit is contained in:
@@ -1,8 +1,14 @@
|
||||
/* This is a code which is going to be compiled together with the library */
|
||||
|
||||
goog.require('ol.Map');
|
||||
goog.require('ol.layer.OSM');
|
||||
goog.require('ol.Loc');
|
||||
|
||||
goog.require('goog.dom');
|
||||
|
||||
function init() {
|
||||
var map = new ol.Map()
|
||||
// .render('map')
|
||||
var map = new ol.Map();
|
||||
map.setContainer(goog.dom.getElement('map'));
|
||||
map.setLayers( [ new ol.layer.OSM() ] );
|
||||
map.setCenter( new ol.Loc(45, 5));
|
||||
map.setZoom(10);
|
||||
|
||||
Reference in New Issue
Block a user