Skip to content

Expose option does not work when requiring streams. #771

@nhunzaker

Description

@nhunzaker

I'm having trouble getting Browserify to respect the expose option if I pipe a stream into it.

For example:

var browserify = require('browserify');
browserify().require(fs.createReadStream('./bar.js'), { basedir: '.' expose: 'bar'})

The contents of the file are included, however no module name is exposed. Am I doing something wrong here?

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