capaj / require-globify

transform for browserify, which allows to require files with globbing expressions
MIT License
70 stars 11 forks source link

Require without extension only works for JS files #6

Closed mparpaillon closed 9 years ago

mparpaillon commented 9 years ago

In my case, I'm requiring Handlebars templates with '.hbs' extension. So it's not working when I try to require them.

So if I have a zoning.hbs file in my template/ directory and I do this

var myTemplates = require('./templates/*.hbs', { hash: true });

I get this

Error: Cannot find module './templates/zoning' from ...

PR incoming

call-a3 commented 9 years ago

I'll investigate this. Please follow the pull request for the resolution.