convert to js only