Skip to content

Commit

Permalink
docs: Dedent needlessly indented example in getter-return docs (#15363)
Browse files Browse the repository at this point in the history
  • Loading branch information
captbaritone committed Nov 28, 2021
1 parent ba6a41d commit 632176d
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions docs/rules/getter-return.md
Expand Up @@ -3,17 +3,17 @@
The get syntax binds an object property to a function that will be called when that property is looked up. It was first introduced in ECMAScript 5:

```js
var p = {
get name(){
return "nicholas";
}
};

Object.defineProperty(p, "age", {
get: function (){
return 17;
}
});
var p = {
get name(){
return "nicholas";
}
};

Object.defineProperty(p, "age", {
get: function (){
return 17;
}
});
```

Note that every `getter` is expected to return a value.
Expand Down

0 comments on commit 632176d

Please sign in to comment.