switched to requirejs instead of curl. added optimized build support