All Projects → mo4islona → Node Blockly

mo4islona / Node Blockly

Blockly for Node.js and Browser via CommonJS module

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Node Blockly

Blocklike
Bridging the gap between block programming and JavaScript.
Stars: ✭ 177 (+51.28%)
Mutual labels:  blockly, browser
Browserify
browser-side require() the node.js way
Stars: ✭ 13,929 (+11805.13%)
Mutual labels:  commonjs, browser
Pax
The fastest JavaScript bundler in the galaxy.
Stars: ✭ 2,626 (+2144.44%)
Mutual labels:  commonjs, browser
Decentraleyes
This repository has a new home: https://git.synz.io/Synzvato/decentraleyes
Stars: ✭ 1,452 (+1141.03%)
Mutual labels:  browser
Browserinterop
Wrapper for Browser JS API for Blazor and JSInterop
Stars: ✭ 112 (-4.27%)
Mutual labels:  browser
Perf Monitor
Performance monitor. Simple UI component that helps you measure performance.
Stars: ✭ 115 (-1.71%)
Mutual labels:  browser
Kosmonaut
A web browser engine for the space age 🚀
Stars: ✭ 1,531 (+1208.55%)
Mutual labels:  browser
Instagram Profilecrawl
💻 Quickly crawl the information (e.g. followers, tags, etc...) of an instagram profile. No login required!
Stars: ✭ 110 (-5.98%)
Mutual labels:  browser
Sushi Browser
Sushi Browser is the next generation browser which mounts the multi-panel and the video support function and so on. Its goal is to be as fantastic as sushi. 🍣
Stars: ✭ 116 (-0.85%)
Mutual labels:  browser
Anti Webminer
Anti-WebMiner protects your PC against web cryptocurrency miners (JS scripts like Coinhive executed in the browser) by modifying Windows hosts file
Stars: ✭ 114 (-2.56%)
Mutual labels:  browser
Galacteek
Browser for the distributed web
Stars: ✭ 114 (-2.56%)
Mutual labels:  browser
Sielo Legacy
An open source browser made with Qt and WebEngine
Stars: ✭ 113 (-3.42%)
Mutual labels:  browser
Robot blockly
A simple way to program ROS robots using blockly.
Stars: ✭ 115 (-1.71%)
Mutual labels:  blockly
Battery.js
A tiny wrapper for the HTML5 Battery Status API.
Stars: ✭ 111 (-5.13%)
Mutual labels:  browser
Mylittledom
High-level DOM-like terminal interface library
Stars: ✭ 116 (-0.85%)
Mutual labels:  browser
Simple Fs
Handles files on indexeddb like you would do in node.js (promise)
Stars: ✭ 111 (-5.13%)
Mutual labels:  browser
Slouch
A JS client for CouchDB that does the heavy lifting
Stars: ✭ 116 (-0.85%)
Mutual labels:  browser
Emacs Application Framework
A free/libre and open-source extensible framework that revolutionizes the graphical capabilities of Emacs, the key to ultimately Live in Emacs
Stars: ✭ 1,932 (+1551.28%)
Mutual labels:  browser
Pxt
Microsoft MakeCode (PXT - Programming eXperience Toolkit)
Stars: ✭ 1,649 (+1309.4%)
Mutual labels:  blockly
Browser Metrics
A collection of metrics tools for measuring performance ⚡️
Stars: ✭ 115 (-1.71%)
Mutual labels:  browser

Blockly for Node.js and Browser via CommonJS module

Build

Supports JavaScript, PHP, Dart, Lua and Python generators.

Live demo with async locales

Install

yarn add node-blockly

Usage

Node.js

All generators

var Blockly = require('node-blockly');

Or you may use standalone generators to decrease memory usage

var Blockly = require('node-blockly/lua');

Browser

All generators

var Blockly = require('node-blockly/browser');

Example

Node.js

var Blockly = require('node-blockly');

var xmlText = `<xml xmlns="http://www.w3.org/1999/xhtml">
        <block type="variables_set">
            <field name="VAR">blockly</field>
            <value name="VALUE">
                <block type="text">
                    <field name="TEXT">Hello Node.js!</field>
                </block>
            </value>
        </block>
    </xml>`;

try {
    var xml = Blockly.Xml.textToDom(xmlText);
}
catch (e) {
    console.log(e);
    return
}

var workspace = new Blockly.Workspace();
Blockly.Xml.domToWorkspace(xml, workspace);
var code = Blockly.JavaScript.workspaceToCode(workspace);

console.log(code)  

Compiled result

var blockly; 

blockly = 'Hello Node.js!';

Browser

Live demo (source)

Internationalization

import Blockly from 'node-blockly/browser';
import De from 'node-blockly/lib/i18n/de';
Blockly.setLocale(De)

Dynamic imports also works but Blockly doesn't re-render workspace. You must re-render it manually after locale loaded

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].