Cleaned up the loaders API quite a lot.