Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create bundles including protobuf generated files #1670

Open
salvani-aldo opened this issue Jun 15, 2020 · 4 comments
Open

Create bundles including protobuf generated files #1670

salvani-aldo opened this issue Jun 15, 2020 · 4 comments

Comments

@salvani-aldo
Copy link

Type of Issue

[x] Bug Report
[ ] Feature Request

Description

I was trying to create a package in angular using protobuf generated code. when i use ng-packagr i encounter the ff error.

ERROR: Could not resolve '../../../generated/AbcApi_pb_service' from dist\esm2015\src\app\modules\angular-abc\services\abc.grpc.service.js

using the command :

ng build --prod && ng-packagr -p package.json

i saw a post here related to my problem Create a bundle including transpiled protobuf #1474

is there any thing we can do on this?

thanks,

Version Information

$ node_modules/.bin/ng-packagr --version
ng-packagr: 5.7.1
@angular/*: 8.2.14
typescript: 3.5.3
rxjs: 6.5.3
node: x.y.z
@types/google-protobuf : 3.7.2
@improbable-eng/grpc-web: 0.12.0
google-protobuf : 3.12.2
@alan-agius4
Copy link
Member

Hi @salvani-aldo, unfortunately without a reproduction it's hard to tell what is happening.

Can you please provide a minimal, reproduction?

@jacobfederer
Copy link

jacobfederer commented Jul 21, 2020

Hi @alan-agius4 ,

I'm facing the same issue, here is a minimal reproduction: https://github.com/jacobfederer/ng-packagr-protobuf

I noticed that running tsc --listFiles with the config file correctly shows the generated files, so the problem is probably not caused by compilation.

Thanks for your help!

@jacobfederer
Copy link

Hi @alan-agius4,

Could you please take a look on this? It would be great to finally move forward with our project.

Thank you :)

@owenhaynes
Copy link

this would be helpful, makes sense to store generated code in a sheared library especially if working with 2 applications within one repo.

At the moment lots of abstractions have to be done to have common code which use these so called common types.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

4 participants