Skip to content

Angular Firebase Error: ENOENT: no such file or directory, open 'google/protobuf/api.proto' #2424

Closed
@francdore

Description

@francdore

Version info

Angular:
8.2.14

Firebase:

= 5.5.7 <8 (This is in my package.json) Came with installation.

AngularFire:
5.4.2

Problem
I'm getting this error with Angular, Firebase and ngUniversal. Everything works fine when I run ng serve. But when I run npm run build:ssr it builds with no errors. Then when I run npm run serve:ssr I get the error below:

C:\Users\user\Documents\app\dist\server\main.js:38890
     throw err;
            ^
Error: ENOENT: no such file or directory, open 'google/protobuf/api.proto'

Steps to set up and reproduce
I installed a fresh Angular app ng new appName --routing, then I installed ngUniversal using ng add @nguniversal/express-engine --clientProject=appName.

So I'm running npm run build:ssr && npm run serve:ssr. It fails on the serve script with the error above.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions