blockly-samples
blockly-samples copied to clipboard
Refactor "getting started" codelab to use the `@blockly/create-package` script.
Category
- Codelabs
Component
https://github.com/google/blockly-samples/tree/master/codelabs/getting_started
Suggested changes
The getting started codelab should use the @blockly/create-package
script instead of having folks clone the starter code from samples.
Additional context
I also think this would be a great time to consider refactoring the structure of the getting started codelab as a whole. I think having multiple save files loaded into the same workspace is extremely confusing to new users. The getting started codelab should address the most common + least confusing use cases.
I would rather have the getting started codelab implement something like the p5.js blocks that @maribethb has an example of!
The Getting Started codelab would have to be significantly changed to use the starter app code. I think completely changing it is the right call, but not sure it should use the starter app code.
Showing/hiding the workspace and having it clear itself in between button presses adds too much complication imo. It's a really clever way of having an organic reason to demonstrate serialization, but it is confusing to new users and gives odd ideas about using multiple workspaces. So I think it's a cool app and we could keep the finished code as an example, but I don't think it's the best fit for the very first codelab, and would like to see a different concept used for the codelab.
The reason I'm not sure using the starter app is the best fit is that it already does a lot of the things one should do in a Getting Started codelab. It might make more sense to have the user write the code that calls Blockly.inject
, the toolbox definition, the serialization code, etc. One of the steps in the current codelab is literally to install Blockly and I think that's a good idea, the starter code shouldn't do all of the work for the user.