Questions tagged [google-blockly]

Google Blockly is a JavaScript library for building visual programming editors. It adds an editor to your app that represents coding concepts as interlocking blocks. It outputs syntactically correct code in the programming language of your choice. It is an open-source project developed and maintained by the google team. Use this tag for questions regarding the implementation of this library or extending the functionality of this library.

Google's Blockly is a web-based, visual programming editor. Users can drag blocks together to build programs. All code is free and open source.

The Blockly library adds an editor to your app that represents coding concepts as interlocking blocks. It outputs syntactically correct code in the programming language of your choice. Custom blocks may be created to connect to your own application.

Blockly is being used by hundreds of projects, most of them educational: Blockly Games, App Inventor, Microsoft MakeCode, Ozo Blockly, micro bit, etc.

Important links

Standard lockup

enter image description here

72 questions
2
votes
1 answer

Custom Programming language in blockly?

How can i change the default block language from javascript to batch? I want to make a block creator that makes batch code .bat file, the default options are javascript, php, lua etc. how can i make a custom one?
user6388479
2
votes
0 answers

Blockly Support for Class Types

I am using blockly in my application to achieve scratch Programming and I have requirement to for creating Complex Types and assigning to Variables while creating them. I have seen this blockly Pull request but this feature not yet available
Sohel Ahmed
  • 149
  • 2
  • 11
2
votes
1 answer

how to make custom blocks shape in blockly?

I'm trying to change the shapes of the blocks in blockly (https://developers.google.com/blockly/) to look more similar to scratch 3
the king
  • 31
  • 2
1
vote
1 answer

Only first block works in a series in Blockly

Description I tried making my own custom blocks in google blockly and made them generate C++ code. They work, but only when separated and aren't attached. However, when they are connected together in a series, only the first block generates code and…
1
vote
1 answer

Blockly element prevents scrolling when mouse is hovering over it

As seen in the image. If you hover over the gray area it prevents scrolling. We're using this in an app where our blockly instance is much larger. This is confusing our clients. Is there a way we could make this blockly component behave more like…
Chris Vouga
  • 555
  • 6
  • 8
1
vote
1 answer

'value.isInitialized': is not true || Flutter desktop error

I am working on Blockly(Blockly is a client-side library for the programming language JavaScript for creating block-based visual programming languages and editors) for the flutter desktop windows. I am using the webview_windows package to display…
1
vote
1 answer

Blocklys Textblock input fields can not be edited when in a Material-UI Modal

I only found https://groups.google.com/g/blockly/c/SDUosMpAFAk to my problem, but it has no answers that could help me, so I created a Codesandbox to reproduce the behavior. https://codesandbox.io/s/gallant-galois-bqjjb The button in the Sandbox…
Marcel Rösler
  • 181
  • 3
  • 14
1
vote
1 answer

Unknown block type in blockly custom blocks

I'm using it with angular (ngx-blockly) and I want to create custom blocks like moveforward and so on ,so I followed all the steps in the tutorial ngx-blockly but I keep getting error about the type of the block and I didn't find information about…
1
vote
3 answers

Calling function within a Function

I have a situation where I generate code from within a Blockly component. The resulting code will have a function that I want to call. According to the Blockly "Generating and Running JavaScript" documentation, I should use eval(). When I look up…
bleuthoot
  • 75
  • 1
  • 7
1
vote
1 answer

Implement Blockly widget into Flutter

I'm new into Flutter and I'm trying to add Blockly into Flutter for an app for kids. I want to be able to program some code into a Flutter app with Blockly, practically I'm trying to create a route with inside a Blockly widget in which the kid,…
1
vote
2 answers

How to get statement stack from input_statement in Blockly?

So this is the block in question Screenshot { "type": "local", "message0": "%{BKY_LOCAL_TITLE}", "args0": [ { "type": "input_dummy" }, { "type": "input_statement", "name": "DEFINE", …
Student01
  • 93
  • 7
1
vote
1 answer

Unable to find Blockly Generator function in Angular application

I am trying to build a Blockly Application using Angular. I installed Blockly using npm . I also added the following scripts in angular.json "scripts": [ "node_modules/blockly/blockly_compressed.js", …
Arbaz Sheikh
  • 217
  • 2
  • 10
1
vote
1 answer

How to implement a blockly demo like this in Angular?

I have implemented this demo in "blockly" and I would like to implement it in Angular as well. I've been reading the official documentation, but haven't found much about this, I don't have much Angular experience either. So I'd appreciate it if you…
Angel
  • 71
  • 5
1
vote
1 answer

how can i get the code of the blocks connected to my custom block by blockly

everyone. Hope you are doing well. I have created my custom block using block factory. The code for block definition is Blockly.Blocks['web'] = { init: function() { this.appendDummyInput() .appendField("When ") .appendField(new…
1
vote
0 answers

Autocomplete in blockly text

I'm just starting into blockly. I have seen that you can ask inputs to the users with a js popup. Is there a way of providing the users with more complex selectors such as an autocomplete textfield? For the moment, calling a jquery and getting the…
Yampeku
  • 583
  • 1
  • 4
  • 21