Fix wrong close element
Use resolvePath to make path not depend on include