Skip to content

Excluded modules are not browserified, but they are removed from the node_modules directory #17

Open
@martinbooth

Description

@martinbooth

Hi,

There is a module binary_parser which is a dependency of mongodb which doesn't seem to play nice with browserify (nexe/nexe#192).

This is somewhat similar to the fact that the aws-sdk doesn't play nice with browserify, except (in this case) I can't rely on the module just being available on the server like the aws-sdk.

I'd like to exclude this module from going into the browserify bundle which I can do quite easily by listing it in the excludes array however the code which deletes all js/json from node_modules wipes away the module and therefore my code doesn't work.

I'm happy to submit a pull request (if you're happy to accept one) to support a scenario where modules can be excluded from browserify whilst retaining them in the node_modeuls directory but just want to check which direction to go with this.

Would you suggest an additional configuration of option to exclude files/directories from the js/json cleanup process at the end, or automatically exclude modules from being cleaned up which are in the excludes array?

Martin

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