Skip to content

Firestore includes two copies of grpc in node_modules which are both very large #96

@lewchuk

Description

@lewchuk

The node_modules for a project containing only firestore as it's dependency are quite large (~150MB depending on exact OS/configuration). Most of this comes from the grpc dependency which is about 50MB and most unfortunately is included twice. Once at the top level node_modules/grpc and once within the node_modules for firestore ./node_modules/@google-cloud/firestore/node_modules/grpc.

Is there any way to only include grpc once when installed? Having this massive dependency makes deploying packages with firestore difficult where the size of the deployment package is constrained.

Environment details

  • OS: mac osx and linux (node 6.10.3 docker image)
  • Node.js version: 6.10
  • npm version: npm 3.10.10 and yarn 1.3.2
  • @google-cloud/firestore version: 0.10.0 and 0.10.1

Steps to reproduce

  1. Create a package.json file with a single dependency: "@google-cloud/firestore": "^0.10.1"
  2. Run yarn install --production or npm install --production
  3. run find . -name grpc and note the two copies of grpc.

Metadata

Metadata

Labels

🚨This issue needs some love.api: firestoreIssues related to the googleapis/nodejs-firestore API.triage meI really want to be triaged.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions