Skip to content

Require is unable to resolve JSON files without explicit ".json" extension #22

@mykolaharmash

Description

@mykolaharmash

For example, I'm trying to build an app with FIrebase Admin SDK, and it fails.

npx ncc index.js -o bundle.js

Module directory "/node_modules/@google-cloud/firestore/build/src/v1beta1" attempted to require "./firestore_client_config" but could not be resolved, assuming external.

/node_modules/@google-cloud/firestore/build/src/v1beta1 folder looks like this:
screenshot 2018-11-19 at 11 44 59

And the require() looks like this const gapicConfig = require('./firestore_client_config');

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