Use style option in vector layer examples
Providing a styleFunction option still works because the layer property is still named styleFunction.
This commit is contained in:
@@ -46,7 +46,7 @@ var vectorSource = new ol.source.Vector({
|
||||
});
|
||||
var vector = new ol.layer.Vector({
|
||||
source: vectorSource,
|
||||
styleFunction: function(feature, resolution) {
|
||||
style: function(feature, resolution) {
|
||||
return styles[feature.get('size')];
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user