This is a work-in-progress pull request that adds support for AstroPi visualisations in PyodideRunner. We have already completed a large piece of work to migrate the _internal_sense_hat.js shim from a Skulpt module to a plain ES6 module. See the last two pages of the technical analysis document for how this was achieved. We now need to integrate this new ES6 module with the editor-ui project's <AstroPiModel> component.
To do so, we need to refactor it so that it doesn't use the Sk.sense_hat global state and instead passes senseHatConfig properties to the React component tree. I think we have successfully completed this refactor and made <AstroPiModel> work with the existing PythonRunner.jsx (Skulpt) but we now need to get it to work with Pyodide. The tests are also broken and need to be updated to provide the senseHatConfig.
This is a work-in-progress pull request that adds support for AstroPi visualisations in PyodideRunner. We have already completed a large piece of work to migrate the _internal_sense_hat.js shim from a Skulpt module to a plain ES6 module. See the last two pages of the technical analysis document for how this was achieved. We now need to integrate this new ES6 module with the editor-ui project's
<AstroPiModel>
component.To do so, we need to refactor it so that it doesn't use the
Sk.sense_hat
global state and instead passessenseHatConfig
properties to the React component tree. I think we have successfully completed this refactor and made<AstroPiModel>
work with the existing PythonRunner.jsx (Skulpt) but we now need to get it to work with Pyodide. The tests are also broken and need to be updated to provide thesenseHatConfig
.