How can I generate Blockly XML?
Is there an easy way to generate Blockly XML? You might want to do this so you can give students block examples in the tutor chat.
Yes! Make your own example using the Blockly playground. Then click the copy button in the top right. That will give you the XML.
To use this in a Tutor Message, include the XML between triple backticks with 'blockly' at the beginning. For example:
```blockly
<xml xmlns="http://www.w3.org/1999/xhtml">
<block type="loops_repeat_ext" id="O)7p9uXz`ad-o*i#Ida2" x="9" y="15">
<value name="TIMES">
<block type="math_number" id="}2|G=)+s,!^g|j9]ef9B">
<field name="NUM">10</field>
</block>
</value>
<statement name="DO">
<block type="io_print1" id="+ryTUmIxwCtuPcFWUa#j">
<value name="ANY0">
<block type="text" id="wtF*|{{Enpw^91Gna?sS">
<field name="TEXT">hello</field>
</block>
</value>
</block>
</statement>
</block>
</xml>
```