Skip to content

About

Blockly enviroment in scala.js with a custom code generator for ScaFi ( Scala FIelds, https://scafi.github.io/ )

Resources

Stars

5 stars

Watchers

1 watching

Forks

Latest commit

 

History

36 Commits

Folders and files

Repository files navigation

blockly2scafi

blockly2scafi is a Blockly environment developed in Scala.js and Javascript with a custom code generator for ScaFi.

Try it in Github pages.

Installation

  • Compile optimized Scala.js with SBT :
sbt fullOptJS

Project structure

The Blockly environment setup and code generator are written in JavaScript in the resource directory:

How to add or edit blocks

  1. Open Blockly Developer Tools .
  2. Click on Import Block Library and upload the file blocks_library.xml.
  3. Define or edit the shape of the blocks using the tool.
  4. Insert or edit the Blockly definition JSON in blocks_library.js.
  5. Add the block in the toolbox in blockly2scafi.js.
  6. Create or edit the code generator function of the block in scafi_generator.js
  7. Remember to download the block library xml from Blockly Developer Tools and save it in blocks_library.xml.

About

Blockly enviroment in scala.js with a custom code generator for ScaFi ( Scala FIelds, https://scafi.github.io/ )

Resources

Stars

5 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages