Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/typescript/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Typescript 返回后花括号的TSLint规则_Typescript_Tslint - Fatal编程技术网

Typescript 返回后花括号的TSLint规则

Typescript 返回后花括号的TSLint规则,typescript,tslint,Typescript,Tslint,有人知道如何使TSLint在这种情况下失败吗 ↓ return{ id: this.user.id, isAdmin: this.user.isAdmin, email: this.profileForm.value.email, password: this.profileForm.value.password, firstName: this.profileForm.value.firstName, secondName: this.

有人知道如何使TSLint在这种情况下失败吗

     ↓
return{
    id: this.user.id,
    isAdmin: this.user.isAdmin,
    email: this.profileForm.value.email,
    password: this.profileForm.value.password,
    firstName: this.profileForm.value.firstName,
    secondName: this.profileForm.value.secondName,
    mobilePhone: this.profileForm.value.mobilePhone,
};
我有这样的tslint.json

"one-line": [true, "check-open-brace", "check-catch", "check-else", "check-whitespace"],
"whitespace": [true, "check-branch", "check-decl", "check-operator", "check-separator", "check-type"]

非常感谢

若要检查我是否理解正确,您希望将其设置为必须将对象分配给变量,然后返回变量?抱歉,问题不清楚)否,我希望强制在返回和大括号之间添加空格。若要检查我是否理解正确,您希望将其设置为必须将对象分配给变量,然后返回变量?对不起,问题不清楚)不,我想强制在return和花括号之间添加空格。