object-shorthand
This commit is contained in:
parent
d7f5def5a3
commit
8896c676be
|
@ -110,7 +110,7 @@
|
|||
"no-unused-expressions": "off",
|
||||
"no-unused-labels": "error",
|
||||
"no-var": "off",
|
||||
"object-shorthand": "off",
|
||||
"object-shorthand": "error",
|
||||
"one-var": "off",
|
||||
"prefer-const": "off",
|
||||
"prefer-object-spread": "error",
|
||||
|
|
|
@ -139,9 +139,9 @@ function writeProtocolFile(outputFile: string, protocolTs: string, typeScriptSer
|
|||
|
||||
if (protocolDts === undefined) {
|
||||
const diagHost: ts.FormatDiagnosticsHost = {
|
||||
getCanonicalFileName: function (f) { return f; },
|
||||
getCurrentDirectory: function() { return '.'; },
|
||||
getNewLine: function() { return "\r\n"; }
|
||||
getCanonicalFileName(f) { return f; },
|
||||
getCurrentDirectory() { return '.'; },
|
||||
getNewLine() { return "\r\n"; }
|
||||
};
|
||||
const diags = emitResult.diagnostics.map(d => ts.formatDiagnostic(d, diagHost)).join("\r\n");
|
||||
throw new Error(`Declaration file for protocol.ts is not generated:\r\n${diags}`);
|
||||
|
|
|
@ -141,7 +141,7 @@ var sys = (function () {
|
|||
args[i] = WScript.Arguments.Item(i);
|
||||
}
|
||||
return {
|
||||
args: args,
|
||||
args,
|
||||
createObject: (typeName: string) => new ActiveXObject(typeName),
|
||||
write(s: string): void {
|
||||
WScript.StdOut.Write(s);
|
||||
|
|
Loading…
Reference in a new issue