grpc / grpc-web

gRPC for Web Clients
https://grpc.io
Apache License 2.0
8.46k stars 762 forks source link

Update ES6 imports with comment about corresponding proto import path. #1311

Closed gonzojive closed 1 year ago

gonzojive commented 1 year ago

I was observing a long import path in the generated code that doesn't work. Outputting the corresponding proto file is helpful for both diagnosing the issue and writing a wrapper for altering the import path to my satisfaction.

Before:

import * as github_com_gonzojive_rules_ts_proto_example_prefix_greeting_pb from '../../../../../github.com/gonzojive/rules_ts_proto/example/prefix/greeting_pb';

After:

import * as github_com_gonzojive_rules_ts_proto_example_prefix_greeting_pb from '../../../../../github.com/gonzojive/rules_ts_proto/example/prefix/greeting_pb'; // proto import: "github.com/gonzojive/rules_ts_proto/example/prefix/greeting.proto"
linux-foundation-easycla[bot] commented 1 year ago

CLA Not Signed