I use browserify-middleware in conjunction with the liveify transformation to serve browserify LiveScript files. For individual files this works fine; however, when serving directories it is broken. My setup is as follows:
Then for example I would like /js/effects.js to compile public/ls/effects.ls into JavaScript, and then run browserify on the result. However, the browserify directory middleware is written in such a way that I need the URL to be /js/effects.ls in order for this work.
That's not how the folder serving works. You have to request /js/effects.ls which will work fine because the browser looks at the mime type, not the file extension.
I use browserify-middleware in conjunction with the liveify transformation to serve browserify LiveScript files. For individual files this works fine; however, when serving directories it is broken. My setup is as follows:
Then for example I would like
/js/effects.js
to compilepublic/ls/effects.ls
into JavaScript, and then run browserify on the result. However, the browserify directory middleware is written in such a way that I need the URL to be/js/effects.ls
in order for this work.