The editor needs JavaScript: it renders your prompt the way zsh does, live, as you drag segments around. The written documentation does not need JavaScript: