Skip to content

Instantly share code, notes, and snippets.

Avatar

Fabien tunguskha

View GitHub Profile
@tunguskha
tunguskha / country-name-to-iso.js
Created Oct 16, 2019
Javascript country name to ISO country code conversion
View country-name-to-iso.js
var isoCode = {
'Afghanistan': 'AF',
'Aland Islands': 'AX',
'Albania': 'AL',
'Algeria': 'DZ',
'American Samoa': 'AS',
'Andorra': 'AD',
'Angola': 'AO',
'Anguilla': 'AI',
'Antarctica': 'AQ',
@tunguskha
tunguskha / CSS-color-var.md
Last active Oct 31, 2020
Darken & Lighten colors in pure CSS using variables.
View CSS-color-var.md
:root {
  /* Base color using HSL */
  --hue: 207;
  --saturation: 64%;
  --light: 44%;
  
  /* Base color in variable */
  --primary-color: hsl(var(--hue), var(--saturation), var(--light));
  /* Base color lighten using calc */
View Gradient shadow in pure CSS.md

Gradient shadow in pure CSS

alt text

HTML
<button>Let's Go !</button>
@tunguskha
tunguskha / How to couple Sass and CSS Variables.md
Last active Mar 19, 2019
How to couple Sass and CSS Var
View How to couple Sass and CSS Variables.md

How to couple Sass and CSS Var

If you use Sass extension, you can work with CSS variables.

First, let's create our css variable.

\:root
  --MyColor: #5966D2
You can’t perform that action at this time.