Skip to content

Instantly share code, notes, and snippets.

View andrejIka's full-sized avatar

Andrej B. andrejIka

View GitHub Profile
@andrejIka
andrejIka / README.md
Created December 21, 2018 06:30 — forked from ngryman/README.md
intellij javascript live templates

intellij javascript live templates

Just a dump of handy live templates I use with IntelliJ. They should also work with WebStorm.

How to

  • Go to settings.
  • Search for live templates.
  • Under the javascript section you should be able to manage your templates.
@andrejIka
andrejIka / README.md
Created September 26, 2018 14:07 — forked from kerryboyko/README.md
VueJS Best Practices Guide

Deverus Vue.js Style Guide

Guide for developing Vue.js applications.

v. 0.0.1

Vue.js is an amazing framework, which can be as powerful as Angular or React, the two big heavy hitters in the world of front-end frameworks.

However, most of Vue's ease-of-use is due to the use of Observables - a pattern that triggers re-renders and other function calls with the reassignment of a variable.

@andrejIka
andrejIka / list.txt
Created May 25, 2018 06:33
php functions
bool isset ( mixed $var [, mixed $... ] )<br>isset — Determine if a variable is set and is not NULL
void echo ( string $arg1 [, string $... ] )<br>echo — Output one or more strings
bool empty ( mixed $var )<br>empty — Determine whether a variable is empty
string substr ( string $string , int $start [, int $length ] )<br>substr — Return part of a string
int count ( mixed $array_or_countable [, int $mode = COUNT_NORMAL ] )<br>count — Count all elements in an array, or something in an object
bool is_array ( mixed $var )<br>is_array — Finds whether a variable is an array
int strlen ( string $string )<br>strlen — Get string length
string sprintf ( string $format [, mixed $args [, mixed $... ]] )<br>sprintf — Return a formatted string
void unset ( mixed $var [, mixed $... ] )<br>unset — Unset a given variable
mixed str_replace ( mixed $search , mixed $replace , mixed $subject [, int &$count ] )<br>str_replace — Replace all occurrences of the search string with the replacement string
@andrejIka
andrejIka / Тестирование.md
Created May 22, 2018 16:03 — forked from codedokode/Тестирование.md
Автоматизированное тестирование

Автоматизированное тестирование

Если ты пишешь код, то наверняка его тестируешь. Если речь о какой-то функции, то ты можешь вызывать ее с разными аргументами, и смотреть, что она вернет. Если ты сверстал сайт, то ты открываешь его в браузере, жмешь ссылки и кнопки, проверяешь что все сделано верно. Это называется ручное тестирование — человек проверяет работу программы. Нельзя ли эту задачу переложить на плечи роботов? Обычно можно, и это называется автоматизированное тестирование.

Тестирование позволяет сделать твой код надежнее, а твою жизнь проще. Ведь согласись, лучше когда ты сам обнаруживаешь и исправляешь ошибку до релиза, чем когда рассерженный заказчик звонит на выходных и требует срочно исправить неработающий функционал.

Тестирование особенно полезно при разработке больших приложений в большой команде, когда ты можешь нечаянно сломать какую-то функцию, которую делал другой человек, и о которой ты не знал. Или когда надо доработать написанный ранее сложный проект.

В больших компаниях может быт

@andrejIka
andrejIka / js-task-1.md
Created May 19, 2018 18:23 — forked from codedokode/js-task-1.md
Задания на яваскрипт (простые)
@andrejIka
andrejIka / gist:499c6a7318853c591e4a87626d0ee1ae
Created November 9, 2017 14:16 — forked from voldy/gist:3699664
Ruby on Rails best practices

Ruby on Rails best practices

Code style

  • Use UTF-8. It’s 21 century, 8bit encodings dead now.
  • Use 2 space indent, not tabs
  • Use Unix-style line endings
  • Keep lines not longer than 80 chars
  • Remove trailing whitespace
@andrejIka
andrejIka / bobp-python.md
Created November 9, 2017 14:15 — forked from sloria/bobp-python.md
A "Best of the Best Practices" (BOBP) guide to developing in Python.

The Best of the Best Practices (BOBP) Guide for Python

A "Best of the Best Practices" (BOBP) guide to developing in Python.

In General

Values

  • "Build tools for others that you want to be built for you." - Kenneth Reitz
  • "Simplicity is alway better than functionality." - Pieter Hintjens
@andrejIka
andrejIka / gist:a4fa94d155ab39ce9727b9199fbb116d
Created October 5, 2017 07:58
Download video from youtube and convert to mp3
brew install youtube-dl
youtube-dl -f bestaudio https://www.youtube.com/watch\?v\=DNceqb81wF0
It's outputs the Tony Anderson - The Way Home-DNceqb81wF0.webm
install ffmpeg on macos
brew install ffmpeg --with-libvpx
@andrejIka
andrejIka / schema-org-structured-data-markup-using-microdata.html
Created September 7, 2017 17:13 — forked from milanaryal/schema-org-structured-data-markup-using-microdata.html
An example of how to mark up a HTML5 webpage using the schema.org schemas and microdata.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<title>Site Title</title>
<link rel="stylesheet" href="/assets/css/style.min.css">