Add data parameter to load callback

This can be used to pass state from the loader to the loader callback.