Make this usable as a Node library