Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
KaiVolland authored Jun 13, 2022
1 parent 96ded97 commit 88546be
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const pointSimplePoint = {
symbolizers: [
{
kind: "Mark",
wellKnownName: "Circle",
wellKnownName: "circle",
color: "#FF0000",
radius: 6
}
Expand All @@ -35,7 +35,7 @@ const layer = new OlLayerVector();

parser
.writeStyle(pointSimplePoint)
.then(olStyle => layer.setStyle(olStyle))
.then(({output: olStyle}) => layer.setStyle(olStyle))
.catch(error => console.log(error));
```

Expand All @@ -47,7 +47,7 @@ var pointSimplePoint = {
name: "OL Style Rule 0",
symbolizers: [{
kind: "Mark",
wellKnownName: "Circle",
wellKnownName: "circle",
color: "#FF0000",
radius: 6
}]
Expand All @@ -56,7 +56,5 @@ var pointSimplePoint = {
var vectorLayer = new ol.layer.Vector();
var parser = new GeoStylerOpenlayersParser.OlStyleParser(ol);
parser.writeStyle(pointSimplePoint)
.then(function(style) {
vectorLayer.setStyle(style);
});
.then(({output: olStyle}) => layer.setStyle(olStyle))
```

0 comments on commit 88546be

Please sign in to comment.