vampeyer / async-programming-promises Goto Github PK
View Code? Open in Web Editor NEWThis is a modules layout package for developers , Axios , and XHTML promises.
License: Apache License 2.0
This is a modules layout package for developers , Axios , and XHTML promises.
License: Apache License 2.0
Good evening everyone. If you are reading this , you have been challenged. simple running a promise with npm run dev , to host your own server , and display the flag in the console. - Capture the flag. 03/06/2023-3:37pm , I have left specific notes for you on creating.mjs - ( which is just a js file thats a module by default , ) lines 88 - 114 is what I covered earlier and is a easy and proper means of using multiple promises to be fulfilled at one time. its a Promise.All or Promise.all . ------ To run the file again , use npm run dev in a console once you open in vs code ( or whatever else that has a console that may run it. ) , may have to install axios using nom install axios , however , there is a local file in here that supports is. Half of all the stuff is exported so the code is super duper short , ----------------------- Once you get the file up and running locally - ( its set to port :3000 now , you can go there and go too localhost:3000 and localhost:3000/home respestively.) ----- To find out how the demonstration works , - run npm run dev , host the site locally. - visit the site at localhost:3000/home , navigate to the , localhost:3000/creating page. and examine the console code when you hit the ALL button. If your server is running properly you will see the multiple promises create and execute and you will have this in your console , if you need help just ask , capture the flag , and , - good luck. ========================================================================= extra notes i decided to leave ........... // This funtion exports a function that calls the counter until two and then , when the function is sert to an onclick buttton , the interval is increased every time , plus the regulaar interval , making the count faster and faster. --------------------------- export function clearIntervalChain(){ / let counter = 2; const wait = new Promise((resolve) => { setInterval(() => { let interval; console.log ("interval") resolve(`Timeout! ${++interval}`); } ,1500); } ); wait.then(text => setText(text)) .finally(() => appendText(`--Done ${interval}`) ) } /
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.