Closed imsamtar closed 3 years ago
I am merging this as an initial commit. @imsamtar, I can not easily find the "XML to JSON format" conversion. Please give me more info about this (which file / function ...). At the moment I see there too too much XML :-)
Please look into this file src/helpers/toolbox.ts which is converted from blockly-html/master/demo.html#L76 from.
And this is how It is being used src/components/Blockly.svelte#L14
The only file which has XML is public/example.xml
The reason It is xml and not json is this function only supports XML blocks
Blockly.Xml.textToDom(xml_code)
...and it seems like there is no equivalent function for json in blockly lib.
https://groups.google.com/g/blockly/c/tI-jqq7DDbY/m/UzUYjP94AQAJ
src/helpers/toolbox.ts
to json I will do thatYes, please try to get rid of the XML if possible. Maybe creating a javascript objects could do that.
On Mon, Apr 12, 2021 at 12:28 PM SAMEER TARIQ @.***> wrote:
Please look into this file src/helpers/toolbox.ts https://github.com/iteria-poc/blockly-html/blob/main/src/helpers/toolbox.ts which is converted from blockly-html/master/demo.html#L76 https://github.com/bwinf/blockly-html/blob/master/demo.html#L76 from.
And this is how It is being used src/components/Blockly.svelte#L14 https://github.com/iteria-poc/blockly-html/blob/main/src/components/Blockly.svelte#L14
The only file which has XML is public/example.xml https://github.com/iteria-poc/blockly-html/blob/main/public/example.xml
The reason It is xml and not json is this function only supports XML blocks
Blockly.Xml.textToDom(xml_code)
...and it seems like there is no equivalent function for json in blockly lib.
https://groups.google.com/g/blockly/c/tI-jqq7DDbY/m/UzUYjP94AQAJ
- May be I need to converted src/helpers/toolbox.ts to json I will do that
— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/iteria-poc/blockly-html/pull/2#issuecomment-817693284, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEAQKR5T7JWSIDMNLNM5TCDTILDNHANCNFSM42Y2P5CA .
Progress so far
@jozef-slezak Please review this