Skip to content

Instantly share code, notes, and snippets.

View Zoha131's full-sized avatar
🎯
Hunting a Job

Md Abir Hasan Zoha Zoha131

🎯
Hunting a Job
View GitHub Profile
@nalexn
nalexn / CancelBag.swift
Last active November 1, 2023 06:43
Collecting AnyCancellable tokens in declarative SwiftUI fashion
// Copyright © 2019 Alexey Naumov. MIT License
import Combine
typealias CancelBag = Set<AnyCancellable>
extension CancelBag {
mutating func collect(@Builder _ cancellables: () -> [AnyCancellable]) {
formUnion(cancellables())
}
@jewelsea
jewelsea / ClipMorph.java
Created January 27, 2012 21:26
JavaFX demo of animating the shape of a visual clip applied to an Image
import javafx.animation.KeyFrame;
import javafx.animation.KeyValue;
import javafx.animation.Timeline;
import javafx.application.Application;
import javafx.event.ActionEvent;
import javafx.event.EventHandler;
import javafx.geometry.Insets;
import javafx.geometry.Pos;
import javafx.scene.Scene;
import javafx.scene.control.Button;