Skip to content

Repository Structure

Rachel Fenichel edited this page Apr 28, 2020 · 7 revisions

There are three main sections:

Codelabs are interactive tutorials that are written in markdown syntax and published at blocklycodelabs.dev. Codelabs mix natural language, code samples, and screenshots. The target user is following along and running the code as they read.

The codelabs directory has a template and one folder per codelab. Each codelab's folder contains the codelab (as a markdown file), and all associated assets (pngs, gif, etc).

Examples are self-contained sample projects demonstrating techniques to include and extend the Blockly library. Examples contain mostly code and a demo web page. Example code should be extremely well-commented to make it easy to copy. The target user may be reading the code, running it locally, or copying code snippets.

The examples directory has one folder per example. Each example can be run with npm install && npm run start, and has a README.md file with additional context or instructions.

Plugins are self-contained pieces of code that add functionality to Blockly. Plugins can add fields, define themes, create renderers, and much more. The target user is a developer who finds and uses the plugin through npm. Plugins defined in this repository are first-party plugins, which means that they are supported by the Blockly team.

The plugins directory has one folder per plugin. To set up a new plugin based on one of the existing templates, use @blockly/create-package.

Clone this wiki locally