Скоро в метархии будет новый Emitter оптимизированый для V8, на него переедут протокод metacom, сервер приложений impress, и т.д. но вообще его полезно даже просто почитать: https://github.com/metarhia/metautil/blob/ee/lib/events.js
const ee = new Emitter(); ee.on('eventA', (data) => { console.log({ data }); // Prints: { data: 'value' } }); ee.emit('eventA', 'value');
const ee = new Emitter(); setTimeout(() => { ee.emit('eventA', 'value'); }, 100); const result = await ee.toPromise('eventA');
const ee = new Emitter(); passReferenceSomewhere(ee); const iterable = ee.toAsyncIterable('eventB'); for await (const eventData of iterable) { console.log({ eventData }); }
Скоро в метархии будет новый Emitter оптимизированый для V8, на него переедут протокод metacom, сервер приложений impress, и т.д. но вообще его полезно даже просто почитать: https://github.com/metarhia/metautil/blob/ee/lib/events.js
const ee = new Emitter(); ee.on('eventA', (data) => { console.log({ data }); // Prints: { data: 'value' } }); ee.emit('eventA', 'value');
const ee = new Emitter(); setTimeout(() => { ee.emit('eventA', 'value'); }, 100); const result = await ee.toPromise('eventA');
const ee = new Emitter(); passReferenceSomewhere(ee); const iterable = ee.toAsyncIterable('eventB'); for await (const eventData of iterable) { console.log({ eventData }); }
BY HowProgrammingWorks - JavaScript and Node.js Programming
To delete a channel with over 1,000 subscribers, you need to contact user support While the character limit is 255, try to fit into 200 characters. This way, users will be able to take in your text fast and efficiently. Reveal the essence of your channel and provide contact information. For example, you can add a bot name, link to your pricing plans, etc. 3How to create a Telegram channel? A few years ago, you had to use a special bot to run a poll on Telegram. Now you can easily do that yourself in two clicks. Hit the Menu icon and select “Create Poll.” Write your question and add up to 10 options. Running polls is a powerful strategy for getting feedback from your audience. If you’re considering the possibility of modifying your channel in any way, be sure to ask your subscribers’ opinions first. Choose quality over quantity. Remember that one high-quality post is better than five short publications of questionable value.
from us