Question: how to get jstl value in javascript?
Answer: To get data from jstl to your javascript : var userName = '<c:out value="${user}"/>'; here ${user} is the data you get as response(from backend).