Skip to content

Restored protobuf.js Message type as generic #422

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

Closed
wants to merge 1 commit into from
Closed

Restored protobuf.js Message type as generic #422

wants to merge 1 commit into from

Conversation

FedeBev
Copy link

@FedeBev FedeBev commented Jul 6, 2018

Fix the error

error TS2314: Generic type 'Message<T>' requires 1 type argument(s).

Message type is defined in the protobufjs package as below

export class Message<T extends object> {
    ...
}

so it should be a generic

@thelinuxfoundation
Copy link

Thank you for your pull request. Before we can look at your contribution, we need to ensure all contributors are covered by a Contributor License Agreement.

After the following items are addressed, please respond with a new comment here, and the automated system will re-verify.

Regards,
CLA GitHub bot

@FedeBev
Copy link
Author

FedeBev commented Jul 6, 2018

All done, I signed the CLA.

@nicolasnoble
Copy link
Member

Please comment on #425 as to why #176 that got solved using #393 was inappropriate.

@FedeBev
Copy link
Author

FedeBev commented Jul 10, 2018

That's wrong because this package use protobufjs 5, in this version Message is not a generic. So #393 it's right and we have to import types for protobufjs 5 in our projects.

Maybe we should add a note in README.md.

@FedeBev FedeBev closed this Jul 10, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Oct 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants