Get started with asynquence-contrib CDN
MIT licensed
Asynquence-contrib is a Python library providing additional features for the asynquence asyncio framework.
Tags:- async
- flow-control
- sequences
- promise
- iterator
- generator
Stable version
Copied!
How to start using asynquence-contrib CDN
// Include the asynquence-contrib library from the CDN
const { sequence, waterfall, parallel, series } = require('https://cdn.cdnhub.io/asynquence-contrib/0.28.2/contrib.js');
// Define some asynchronous functions
const fetchData = (url) => new Promise((resolve) => {
setTimeout(() => {
resolve({ data: `Data from ${url}` });
}, 1000);
});
const processData = (data) => new Promise((resolve) => {
setTimeout(() => {
const processedData = data.data.toUpperCase();
resolve(processedData);
}, 500);
});
// Use sequence to execute functions in a sequence
const sequenceExample = () => sequence(
() => fetchData('https://example.com'),
(data) => processData(data)
).then((processedData) => console.log(processedData));
// Call the sequenceExample function
sequenceExample();
Copied!
Copied!
Copied!
Copied!
Copied!
All versions
0.1.0-a
0.1.1-a
0.1.10-a
0.1.10-b
0.1.10-c
0.1.10-d
0.1.10-e
0.1.10-f
0.1.10-g
0.1.10-h
0.1.10-i
0.1.10-j
0.1.10-k
0.1.10-l
0.1.10-m
0.1.11-a
0.1.2-a
0.1.3-a
0.1.4-a
0.1.5-a
0.1.6-a
0.1.6-b
0.1.7-a
0.1.7-b
0.1.8-a
0.1.8-b
0.1.9-a
0.10.0-a
0.10.1-a
0.11.0
0.12.0
0.12.1
0.13.0
0.14.0
0.15.0
0.16.0
0.17.0
0.18.0
0.19.0
0.2.0-a
0.2.1-a
0.2.2-a
0.2.2-b
0.2.3-a
0.20.0
0.21.0
0.22.0
0.23.0
0.24.0
0.25.0
0.26.0
0.27.0
0.28.0
0.28.1
*** 0.28.2
0.3.0-a
0.3.0-b
0.3.0-c
0.3.1-c
0.4.0-a
0.5.0-a
0.5.0-b
0.5.1-a
0.5.2-a
0.5.2-b
0.5.2-c
0.6.0-a
0.6.1-a
0.6.2-a
0.7.0-a
0.7.0-b
0.7.0-c
0.7.1-a
0.8.0-a
0.9.0-a
0.9.1-a