Skip to content

Instantly share code, notes, and snippets.

View JQuezada0's full-sized avatar

Johnil Quezada JQuezada0

  • Appy People
  • Clermont, Florida
  • 10:01 (UTC -04:00)
View GitHub Profile
@JQuezada0
JQuezada0 / effect-stream-fifo.ts
Created May 10, 2025 15:18
Effect-ts FIFO Queue Stream
import { Chunk, Deferred, Effect, Option, Queue, Schedule, Stream } from "effect"
/**
* Creates a stream that processes items from a queue one at a time, and new events
* are only pulled from the queue when the previous event has been processed by the stream.
*
* This means that when the stream terminates, anything unprocessed is still in the queue.
*/
const make = Effect.fn(function* <T>() {
const queue = yield* Queue.unbounded<T>()
@JQuezada0
JQuezada0 / designer.html
Created February 16, 2015 15:52
designer
<link rel="import" href="../polymer/polymer.html">
<polymer-element name="my-element">
<template>
<style>
:host {
position: absolute;
width: 100%;
height: 100%;