Developer Resources
- Qworum specification: The target audience for this specification are the developers of Qworum applications and services, as well as Qworum platform developers.
- JavaScript library for Web Pages (API documentation): With this JavaScript ES module, websites can use the advanced browser functionality that is provided by Qworum's browser extension.
- Demo project: This GitHub repository contains the code base for a Qworum-based distributed web application.
- Demo in pseudocode: This is a TypeScript pseudocode that describes the demo project. This is an easy way of seeing an overview of how the demo is structured.
- Other demos: Here are some integration tests for the Qworum browser extension.
- Visual Studio Code extension: Provides XML snippets for writing static Qworum scripts.
- Google group: Visit this group for feature requests, bug reports and general discussion.
Downloads
Easy-to-use JavaScript library for developers
Use browser-side JavaScript for building web applications that combine local and remote interactive microservices. Qworum's JavaScript library for web frontends is available on the Skypack CDN. Here is how Qworum works:
// Adds an article to a shopping cart on an e-commerce website.
// (The end-user is on an article details page.)
import { Qworum } from "https://cdn.skypack.dev/@qworum/qworum-for-web-pages@1.0.9";
const
// Sample article details.
article = {
"id" : "8b1d5802",
"title": "Classic ankle boots",
"price": {"EUR": 29.99}
},
// Create a Qworum script.
addToCartScript = Qworum.Script(
Qworum.Sequence(
// Add the article to the shopping cart ...
// (Redirects the end-user to the remote shopping cart service.)
Qworum.Call(
['@', 'shopping cart'], 'https://shopping-cart.example/add-article/',
{
name : 'article',
value: Qworum.Json({article})
}
),
// ... then go back to the article details page on the e-commerce site.
Qworum.Goto('index.html')
)
),
addToCartButton = document.getElementById('add-to-cart-button');
// Execute the Qworum script when the user clicks on the add-to-cart button.
addToCartButton.addEventListener('click', async () => {
// Add the article to the visitor's shopping cart.
await Qworum.eval(addToCartScript);
});
Local development
The Qworum browser extension is enabled for local development by default. The web origins that are enabled for local development are:
http://localhost:8080
,http://27.0.0.1:8080
(the TCP port 8080 is often used in the Java world)http://localhost:3000
,http://27.0.0.1:3000
(port 3000 is often used in Deno or Node.js projects)http://localhost:5500
,http://27.0.0.1:5500
(5500 is the default port for VS Code's Live Server extension)http://localhost:5501
,http://27.0.0.1:5501
(alternative Live Server port)http://localhost:5502
,http://27.0.0.1:5502
(alternative Live Server port)