ADd JS support functions