nodefy: convert AMD modules to node.js

I’ve been using amd-utils on almost all my projects and sometimes I find myself wanting to use some of the methods on my node.js programs as well, so I decided to write a tool to convert the modules automatically.

The tool uses Esprima internally so it will keep the indentation, comments and it should work as long as the code can be parsed by Esprima. It will do as few replacements as possible to avoid undesired side effects.

Check the project repository for more info and please use the issue tracker for feature requests, bug reports and questions/feedback.



Now this is interesting! I've been trying to figure out what to do with a lib similar to your amd-utils. This is something I wrote to use with Node and lately I've been wanting to use that with frontend side too.

At first I thought it might make sense just to add some UMD kludges around. Your approach is way nicer. I think I'll convert the whole source to use AMD definition just like yours (might do micromodules while at it) and then use nodefy to get the whole work in Node.

Thanks a lot for this tool! :)