requiring as a CommonJS module doesn't work #61

Open
mrak opened this Issue Aug 12, 2014 · 4 comments

Projects

None yet

5 participants

mrak commented Aug 12, 2014

It may be related to how you convert formatter.js to CommonJS, but all of the require statements for internal modules are not using relative paths.

In the main file (dist/common/formatter.js:8-10) the require statements should be like this:

var patternMatcher = require('./pattern-matcher');
var inptSel = require('./inpt-sel');
var utils = require('./utils');

Notice the relative paths being used. The compiled CommonJS files should all be using relative paths for in-module requires 😄

Owner

Have a fix being used in a few of my smaller libs. Will port over to formatter when time permits. Thank you for reporting.

@jaridmargolin jaridmargolin added the bug label Aug 22, 2014

👍

jamuhl commented Nov 4, 2014

+1

Kureev commented May 26, 2015

If I'll fix it, would you accept PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment