I have the following line of code:
which gives this error:
Uncaught TypeError: switchEditors.switchto is not a function
Searching around I found out that, due to changes to the core in WordPress 4.3,
switchEditors.switchto() is not available/usable now.
Do you know how can I fix it?
You can see the complete code here.
switchEditors.switchto()and how it was changed in latest versions of WordPress.
switchEditors.switchEditor(). Here's the relevant file.