Skip to content

Instantly share code, notes, and snippets.

View OLDIN's full-sized avatar
🏠
Working from home

Vladyslav OLDIN

🏠
Working from home
View GitHub Profile
@OLDIN
OLDIN / rect-starlink-cable-hack.md
Created November 29, 2022 19:04 — forked from darconeous/rect-starlink-cable-hack.md
Hacking the Rectangular Starlink Dishy Cable
@OLDIN
OLDIN / mac-setup-redis.md
Created January 31, 2022 20:55 — forked from tomysmile/mac-setup-redis.md
Brew install Redis on Mac

type below:

brew update
brew install redis

To have launchd start redis now and restart at login:

brew services start redis
@OLDIN
OLDIN / readme.md
Created March 3, 2020 17:55 — forked from navix/readme.md
Wait for all animations to finish before :leave in Angular 7 (@angular/animations)

Wait for all animations to finish before :leave in Angular 7

Including child components.

@Component({
  ...
  animations: [
    trigger('host', [
 transition(':enter, :leave', [

Angular Interview Questions

Some basic questions going from easy to difficult. A more exhaustive list of more questions from the community can be found here.

Easy

  • Whats the difference between components and directives? [ANSWER]: Components are widgets while directives more like decorators for elements and/or components.
  • How do you get a reference to a child component? [ANSWER]: ViewChild/ViewChildren or ContentChild/ContentChildren
  • What is the difference between ViewChild and ContentChild?
  • Whats the difference between NgModules and ES2015 Modules?
  • How do you lazy load components and why is lazy loading important?
  • Explain Observables and why they are useful.
@OLDIN
OLDIN / README.md
Created December 18, 2018 14:43 — forked from twolfson/README.md
Quick and dirty database dump to S3 via Node.js

We are implementing database dumping which is straightforward but can be tedious to setup. Here's our setup:

  1. Create AWS user for db backups (e.g. db-backups-{{app}})
    • Save credentials in a secure location
    • If adding db scrubbing, use a separate user (e.g db-scrubs-{{app}})
  2. Create bucket for S3 access logging (e.g. s3-access-log-{{app}})
  3. Create consistently named bucket for db dumps (e.g. db-backups-{{app}})
    • Enable logging to s3-access-log-{{app}} with prefix of db-backups-{{app}}
  4. Add IAM policy for bucket access
  • Select user -> Choose "Add inline policy"
@OLDIN
OLDIN / tokens.md
Created July 28, 2018 11:01 — forked from zmts/tokens.md
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Preconditions:

В данной заметке рассматривается работа JWT с симметичным алгоритмом шифрования (HS256/HS384/HS512)

Основы:

Аутентификация(authentication, от греч. αὐθεντικός [authentikos] – реальный, подлинный; от αὐθέντης [authentes] – автор) - это процесс проверки учётных данных пользователя (логин/пароль). Проверка подлинности пользователя путём сравнения введённого им логина/пароля с логином/паролем, сохранённым в базе данных пользователей.

Авторизация(authorization — разрешение, уполномочивание) - это проверка прав пользователя на доступ к определенным ресурсам.

@OLDIN
OLDIN / rename_js_files.sh
Created May 8, 2018 15:42 — forked from afternoon/rename_js_files.sh
Rename .js files to .ts
find app/src -name "*.js" -exec sh -c 'mv "$0" "${0%.js}.ts"' {} \;