-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Labels
Description
Describe the bug
When trying to use @bufbuild/protobuf package the server can't compile the files where there are imported functions from this module.
To Reproduce
Steps to reproduce the behavior
- Install @bufbuild/protobuf
- Include create, toBinary or other function from the package in a router file
- compile to get error
‧ Error: [files:load:E:/projects/my-project/mocks/routes/my-test-route.ts] Error loading file E:/projects/my-project/mocks/routes/my-test-route.ts: Unexpected token '{'
SyntaxError: Unexpected token '{'
at compileSourceTextModule (node:internal/modules/esm/utils:338:16)
at ModuleLoader.importSyncForRequire (node:internal/modules/esm/loader:353:18)...
Expected behavior
Able to use the package to return data as proto binary object
Logs
If applicable, add logs to help explain your problem.
** Operating system, Node.js an npm versions, or browser version (please complete the following information):**
- OS: windows
- Node.js: v22.14.0
- npm: 11.2.0
- Browser: cmd, powershell, bash
Additional context
Add any other context about the problem here.