Skip to content

Instantly share code, notes, and snippets.

View droganaida's full-sized avatar

Aida Drogan droganaida

View GitHub Profile
@droganaida
droganaida / ScrollViewAdapter.cs
Created November 1, 2017 12:18
Add item to Scroll Rect content runtime (Unity3d)
using System.Collections;
using UnityEngine;
using UnityEngine.UI;
public class ScrollViewAdapter : MonoBehaviour {
public RectTransform prefarb;
public Text countText;
public RectTransform content;
@droganaida
droganaida / sticky_footer.html
Last active September 15, 2023 15:09
3 способа, как прижать footer к низу страницы
@droganaida
droganaida / koa-app.js
Created August 13, 2023 14:13
Simple SSL Koa JS server (HTTPS for Localhost)
const Koa = require('koa');
const path = require('path');
const serve = require('koa-static');
const http = require('http');
const https = require('https');
const fs = require('fs');
const commonDir = path.join(__dirname, '..', 'Client');
const app = new Koa();
const http = require('http');
const url = require('url');
const port = 6006;
const requestHandler = (request, response) => {
const query = url.parse(request.url, true).query;
if (query && query.count && (query.count > 0)) {
@droganaida
droganaida / ScrollViewAdapterConnected.cs
Created November 12, 2017 11:41
Unity3d C# ScrollView Adapter with Internet connection
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class ScrollViewAdapterConnected : MonoBehaviour {
public RectTransform prefarb;
public Text countText;
public RectTransform content;
var soap = require('soap');
var Cookie = require('soap-cookie');
exports.get = function(req, res){
var url = 'http://ws.example.com/wsclientPath?wsdl';
soap.createClient(url, function(err, client) {
if (err) {
res.send(err);
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<title>CSS Read more / Read less button | demo by #BlondieCode</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
/* Common styles */
html, body {
min-height: 100vh;
@droganaida
droganaida / childProcess.js
Last active September 27, 2022 12:32
Node.js child_process demo. Test for exec(), execFile() and spawn().
const childProcess = require('child_process');
function execProcess(command) {
childProcess.exec(command, function(error, stdout, stderr) {
console.log(`stdout: ${stdout}`);
console.log(`stderr: ${stderr}`);
@droganaida
droganaida / rainbowButtons.html
Last active April 15, 2022 07:07
Rainbow gradient for the group of buttons depending on position
<html>
<head>
<title>Common CSS background on button group by #BlondieCode</title>
<style>
body {
display: flex;
flex-direction: column;
}
footer {
text-align: center;
@droganaida
droganaida / lazy-loading.html
Created January 23, 2020 08:42
Intersection Observer + custom lazy loading demo
<html>
<head>
<title>Lazy loading by #Blondiecode</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
body {
font-family: Arial, "Helvetica Neue", Helvetica, serif;
}
footer {