connectrpc / connectrpc.com

Docs, governance, and RFCs for Connect: Protobuf RPC that works.
https://connectrpc.com
Apache License 2.0
15 stars 18 forks source link

Fix code example in Node.JS getting started #147

Closed jchadwick-buf closed 4 months ago

jchadwick-buf commented 5 months ago

When running the code example as-presented, the following error occurs:

SyntaxError: The requested module '@connectrpc/connect' does not provide an export named 'ConnectRouter'

I am not sure exactly why this is. It may be due to a change in a newer TypeScript or tsx version than when this was tested, that causes tsx to not prune the import if it is not a type import.

Either way, this should be more correct anyways, so it seems like the best way to go.

vercel[bot] commented 5 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
connect ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 1, 2024 5:27pm