Skip to content

yokobond/scratch-microbit-more

Repository files navigation

This project moved to a new repository yokobond/mbit-more-v2.

scratch-microbit-more

Version Documentation Maintenance License: MIT

Full-functional extension of micro:bit for Scratch3

Setup Development Environment

Download the Scratch3 repositories according to the supporsed directory configuration.

.
|-- scratch-microbit-more
|-- scratch-vm
|-- scratch-gui

Install node modules and setup to use local repo for development.

cd ./scratch-microbit-more
npm install
npm run setup:local
npm run install:local

Install into Scratch3

To install this extention into your selfbuild Scratch3, execute scripts/install.js with options as follows.

node ./scripts/install.js --gui="../scratch-gui" --vm="../scratch-gui/node_modules/scratch-vm" --url="https://yokobond.github.io/scratch-microbit-more/dist/microbitMore.mjs"
  • --gui : location of scratch-gui from current dir.
  • --vm : location of scratch-vm form current dir.
  • --url : URL to get its module as a lodable extension for Xcratch.

CAUTION: This script will change 'extension default' in scratch-gui/src/lib/libraries/extensions/index.jsx as follows.

change from the original code

export default [...];

to

const extensions = [...];
export default extensions;

It may break installation mechanism of the other extensions.

Xcratch Module Building

Build module as loadable extension for Xcratch.

node ./scripts/build.js --name=microbitMore --block="./src/block" --entry="./src/entry" --vm="../scratch-vm" --gui="../scratch-gui" --output="./dist"
  • --name: name of the module file (without '.mjs').
  • --block : location of block files from current dir.
  • --entry : location of entry files from current dir.
  • --gui : location of scratch-gui from current dir.
  • --vm : location of scratch-vm form current dir.
  • --output : location to save module form current dir.

Author

👤 Koji Yokokawa

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2020 Koji Yokokawa.
This project is MIT licensed.


This README was generated with ❤️ by readme-md-generator