This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@use "sass:selector"; | |
@use "sass:string"; | |
.grid { | |
display: grid; | |
grid-template-columns: repeat(2, 1fr); | |
grid-template-rows: repeat(5, 1fr); | |
grid-column-gap: 16px; | |
grid-row-gap: 24px; | |
&_item { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$bp_xs: 600px; | |
$bp_sm: 960px; | |
$bp_md: 1280px; | |
$bp_lg: 1920px; | |
$bp_xl: 3200px; | |
$bp_xxl: 5760px; | |
@mixin bp_lt-xs { | |
@media screen and (max-width: #{$bp_xs - 1px}) { | |
@content; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin random-bgr(){ | |
background: rgb(random(255), random(255), random(255)); | |
} | |
$num_colors: 20; | |
@for $i from 0 to $num-colors { | |
container_#{$i} { | |
@include random-bgr(); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin random-bgr(){ | |
background: rgb(random(255), random(255), random(255)); | |
} | |
$num_colors: 20; | |
@for $i from 0 to $num-colors { | |
container_#{$i} { | |
@include random-bgr(); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@use "sass:map"; | |
.container-outer { | |
display: flex; | |
padding: 32px; | |
align-items: center; | |
flex-direction: column; | |
background-color: lightblue; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 | |
2 | |
3 | |
4 | |
5 | |
6 | |
7 | |
8 | |
9 | |
10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 | |
2 | |
3 | |
4 | |
5 | |
6 | |
7 | |
8 | |
9 | |
10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 | |
2 | |
3 | |
4 | |
5 | |
6 | |
7 | |
8 | |
9 | |
10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://egghead.io/lessons/typescript-deep-copy-aka-clone-objects-using-typescript | |
function deepcopy<T>(o: T): T { | |
return JSON.parse(JSON.stringify(o)); | |
} | |
const foo = { | |
x: { | |
y: { | |
z: 123 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Component, OnInit, OnDestroy } from '@angular/core'; | |
import {Http} from "@angular/http"; | |
import { LocalCacheService } from "./local-cache.service"; | |
@Component({ | |
selector: 'app-example', | |
templateUrl: './app.component.html', | |
styleUrls: ['./app.component.scss'] | |
}) | |
export class ExampleComponent implements OnInit, OnDestroy { |
NewerOlder