update js based on environment