From 92e3d3e02a886839c75aca74dab4d0ea4cef8eb8 Mon Sep 17 00:00:00 2001 From: Andrew Jennings Date: Tue, 14 Jul 2020 11:54:33 -0700 Subject: [PATCH] Disable ESLint and TypeScript on JS protobuf file I was getting TypeScript errors on the generated protobuf file. These directives to turn off ESLint and TypeScript are just comments. They shouldn't affect anyone who is not using ESLint or TypeScript. A similar change was made in the grpc/grpc-web project: https://github.com/grpc/grpc-web/pull/752 --- src/google/protobuf/compiler/js/js_generator.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/google/protobuf/compiler/js/js_generator.cc b/src/google/protobuf/compiler/js/js_generator.cc index 02a89549d8..22bbcc8294 100644 --- a/src/google/protobuf/compiler/js/js_generator.cc +++ b/src/google/protobuf/compiler/js/js_generator.cc @@ -1654,6 +1654,8 @@ void Generator::GenerateHeader(const GeneratorOptions& options, " * @public\n" " */\n" "// GENERATED CODE -- DO NOT EDIT!\n" + "/* eslint-disable */\n" + "// @ts-nocheck\n" "\n"); }