Skip to content

Instantly share code, notes, and snippets.

View kopyl's full-sized avatar

Oleh kopyl

View GitHub Profile
class SuperDict(dict):
def convert_dict_to_SuperDict(self, key, value):
if type(value) == dict:
self[key] = self.__class__(value)
if type(value) == list:
for n, item in enumerate(value):
if type(item) == dict:
self[key][n] = self.__class__(item)
from __future__ import annotations
def return_func(
all_value: Optional = None,
reminder: bool = True
) -> Callable:
"""
Initialize:
returns = return_func()
@kopyl
kopyl / superdict.py
Created July 23, 2021 09:45
SuperDict
class SuperDict(dict):
def convert_dict_to_SuperDict(self, key, value):
if type(value) == dict:
self[key] = self.__class__(value)
if type(value) == list:
for n, item in enumerate(value):
if type(item) == dict:
self[key][n] = self.__class__(item)
@kopyl
kopyl / component.ts
Created May 3, 2022 15:06
Animate Child working example
import {
animateChild,
query,
group,
style,
animate,
trigger,
transition,
} from "@angular/animations"
@kopyl
kopyl / component.ts
Created May 3, 2022 16:40
Hamburger icon angular animations
import {
Component,
OnInit,
Input,
HostBinding,
HostListener,
} from "@angular/core"
import {
animateChild,
@kopyl
kopyl / component.ts
Created May 3, 2022 17:15
Working burger
import {
Component,
OnInit,
Input,
HostBinding,
HostListener,
} from "@angular/core"
// @Input
@kopyl
kopyl / component.sass
Created May 4, 2022 00:40
Working hamburger icon
:host
cursor: pointer
div.container
display: grid
height: 100%
div.hamburger
justify-items: center
display: grid
https://www.sec.gov/Archives/edgar/data/1935555/000193555522000001/xslFormDX01/primary_doc.xml
https://labsnews.com/en/news/business/brazils-clubbi-snags-12m-series-a-to-scale-up-its-grocery-supply-marketplace/
https://yourstory.com/2022/06/funding-vernacular-short-news-app-way2news-westbridge-capital/amp
https://www.yahoo.com/now/webio-secures-4m-scale-conversational-120000825.html
https://www.wtae.com/article/pat-mcafee-plum-athletics-donation/40452304
https://www.wamda.com/2022/06/huspy-raises-37-million-series-led-sequoia-capital-india
https://www.venturecapitaljournal.com/getquin-snags-15m-series-a/
https://www.vccircle.com/affle-picks-up-13-stake-in-indus-os-at-90mn-valuation
https://www.reuters.com/markets/deals/uk-green-supply-chain-startup-circulor-raises-25mln-us-expansion-2022-06-28/
https://labsnews.com/en/articles/business/brazils-zippi-attracts-tiger-global-to-16m-series-a/
import SafariServices
import SwiftUI
struct Popover: View {
@State private var content = ""
var body: some View {
VStack(spacing: 16) {
Text("URL")
.font(.headline)
@kopyl
kopyl / Json.swift
Created January 12, 2025 15:39
Encode and decode Array of Int in and from JSON
import Foundation
func createMessageData(_ messsagePayload: [Int]) -> String {
let encoder = JSONEncoder()
let data = try! encoder.encode(messsagePayload)
let messsagePayloadString = String(data: data, encoding: .utf8)!
return String(messsagePayloadString)
}