Skip to content

Instantly share code, notes, and snippets.

View sudodoki's full-sized avatar

Джон, просто Джон sudodoki

View GitHub Profile

Basic pre-requisites

  • Some utilities:
sudo apt-get install vim tmux git
  • Copy/paste from the command line:
sudo apt-get install xclip
@sudodoki
sudodoki / .jshintrc
Last active December 28, 2015 00:09 — forked from nkbt/.jshintrc
{
// All credits go to @nkbt
// --------------------------------------------------------------------
// --------------------------------------------------------------------
// JSHint Configuration, Strict Edition
// --------------------------------------------------------------------
//
// This is a options template for [JSHint][1], using [JSHint example][2]
// and [Ory Band's example][3] as basis and setting config values to
// be most strict:
Напишите конструктор my$, который принимает аргументом DOM селектор.
Реализуйте методы width, height которые соответсвенно изменяют ширишу и высоту всех селекторов,
которые мы определили ранее.
Пример:
var $div = my$('div')
console.log( $div ) //показать все div на странице.
var $red = my$('.red')
---
layout: post
title: "JS Course lessons & materials"
date: 2013-12-18 10:48
comments: true
categories:
---
#Links:
[http://programmers.stackexchange.com/questions/16528/single-statement-if-block-braces-or-no](http://programmers.stackexchange.com/questions/16528/single-statement-if-block-braces-or-no)
angular.element(document.body).injector().invoke(function($http) { $http.get('/api/').then(console.log.bind(console),console.error.bind(console))})
var fs = require('fs');
var cheerio = require('cheerio');
var Chance = require('chance');
var chance = new Chance();
function getRandomData(type, hint) {
if (type == 'number') {
return (Math.random() * 1000000 | 0) / 100;
} else if (type == 'boolean') {
return Math.random() >= 0.5;
19:42 alexspeller: spenguin: imagine the controller layer as a spiderweb with flies on
19:42 alexspeller: spenguin: controllers are like the webbing and the struggling flies are your data
19:43 spenguin: right
19:43 alexspeller: spenguin: the routing layer is the spider. The spider responds to the weather (i.e. URL changes, user input, websocket events, etc etc) by moving flies around (setting controller content to various data)
19:45 alexspeller: due to convention a lot of this is automatic (hitting /posts/1 will find Post id 1 and set the model property of the PostController to that post for example) but it doesn't have to be automatic
19:45 alexspeller: you can override setupController to set the post model to a different controller or you can override model hook so PostRoute finds a different model or multiple models or no model
19:46 alexspeller: the strands of the web are "needs". They connect controllers together.
19:48 alexspeller: So don't get confused by thinking there should always be a 1:1 relatio

Typography

Headings

Headings from h1 through h6 are constructed with a # for each level:

# h1 Heading
## h2 Heading
### h3 Heading
var google_conversion_id = 1234567890;
var google_custom_params = window.google_tag_params;
var google_remarketing_only = true;
window.onload = function(){
// save old document.write
var dw = document.write;
// change document.write temporary
document.write = function(node){
@sudodoki
sudodoki / poznan.md
Last active August 29, 2015 14:24 — forked from mmalecki/poznan.md

Food

  • Racja Mięsa - if you like meat, that's your place. Amazing tartars.
  • Święta Krowa - a decent burger place
  • Pizza a Pezzi - great pizza
  • Ptasie radio - various food, has has some Italian stuff
  • Manekin - pancakes
  • Sofa - good for lunch

Drinks

  • Lot Chmiela - lots of craft beers