diff --git a/docs/rules/func-names.md b/docs/rules/func-names.md index cd699400698..b051d9b9bef 100644 --- a/docs/rules/func-names.md +++ b/docs/rules/func-names.md @@ -38,6 +38,10 @@ Examples of **incorrect** code for this rule with the default `"always"` option: Foo.prototype.bar = function() {}; +const cat = { + meow: function() {} +} + (function() { // ... }()) @@ -50,6 +54,10 @@ Examples of **correct** code for this rule with the default `"always"` option: Foo.prototype.bar = function bar() {}; +const cat = { + meow() {} +} + (function bar() { // ... }()) @@ -78,6 +86,10 @@ Examples of **correct** code for this rule with the `"as-needed"` option: var bar = function() {}; +const cat = { + meow: function() {} +} + (function bar() { // ... }())