Transform resources in js values