fix ajax bugs and remove compiled js file from public folder