I am using Emacs and js3-mode
to edit some javascript code. After I write the following code and indent it, I see this:
var returnValue = someFunction(function () {
console.log('This is a callback');
});
What I want is this:
var returnValue = someFunction(function () {
console.log('This is a callback');
});
It looks like js3-mode
is trying to align the callback with the call to someFunction
, but I don't want that. How do I change the indentation style?
Side note: That code was just an example, it's not actually the code I'm editing, but the situation is similar.
从js3-mode wiki ,将其添加到init文件中
(setq js3-consistent-level-indent-inner-bracket t)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.