allow using different loaders for loading a resource