Skip to content

AMD module definition breaks Webpack #19

@saltyJeff

Description

@saltyJeff

This isn't really an issue with the code, but it does hurt integration with Webpack. Webpack uses their own custom "version" of AMD, which injects a pseudo-object that takes over from AMD.

Since the fake AMD is not an function, this line fails:

if (typeof define !== 'function') { var define = require('amdefine')(module); }

Simply taking out this line on every single file will allow Webpack to handle this module. I already have a copy of the module with that line taken out from every file, let me know if you would be interested in merging my PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions