最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - Webstorm turn off new spaces in anonymous function declaration - Stack Overflow

programmeradmin0浏览0评论

e.g. I have this:

exports.getsertHexId = function (table, hex) {

Webstorm 8's auto-indent is creating the space between the keyword function and the open paren (.

Its settings spaces options cover:

  • Function declaration parentheses
  • Function call parentheses
  • 'if' parentheses
  • . . .

Confused since this should be covered under function declaration parentheses I thought. Can this be properly configured? Is it a bug?

e.g. I have this:

exports.getsertHexId = function (table, hex) {

Webstorm 8's auto-indent is creating the space between the keyword function and the open paren (.

Its settings spaces options cover:

  • Function declaration parentheses
  • Function call parentheses
  • 'if' parentheses
  • . . .

Confused since this should be covered under function declaration parentheses I thought. Can this be properly configured? Is it a bug?

Share Improve this question asked Apr 4, 2014 at 16:59 djechlindjechlin 60.8k38 gold badges171 silver badges300 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 25

Scroll down further and it's the option "In function expression." Because function() { ... } is an expression which returns a value, that value being a function.

发布评论

评论列表(0)

  1. 暂无评论