Fixed more browserify export problems, and fixed a bug in doc create