add module file with resource promise wrapper