Commonjs pb exports do not carry intellisense #18
Labels
enhancement
New feature or request
good first issue
Good for newcomers
javascript
triaged
Issue has been triaged
What version of protobuf and what language are you using?
Version: v3.6.1
Language: Javascript
What operating system (Linux, Windows, ...) and version?
Ubuntu 20.04, x86_64
What runtime / compiler are you using (e.g., python version or gcc version)
protoc pre-built compiler
What did you do?
Steps to reproduce the behavior:
simple.proto
. I took it from this example, modified to "proto3"protoc --js_out=import_style=commonjs,binary:. simple.proto
const Schema = require('./simple_pb');
const test = new Schema.Test1();
Test1()
class, nor for expected operations it's instancesWhat did you expect to see
Intellisense for the
simple_pb
operations on the default export.What did you see instead?
No Intellisense, but the operations themselves do execute (setting values, serialzing to Binary).
I was able to "fix" the issue by changing the last line of the
simple_pb.js
file. The goog export extension did not work, so I just commented it out and spread thegoog
andproto
objects intomodule.exports
:The text was updated successfully, but these errors were encountered: