passing vms to js