remove JSON parsing, use directionsConfig variable instead