$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Variáveis Nativas com CSS
Search
Simone Amorim
February 11, 2017
Technology
1
120
Variáveis Nativas com CSS
Variáveis Nativas com CSS x Variáveis em pre-processadores
Simone Amorim
February 11, 2017
Tweet
Share
More Decks by Simone Amorim
See All by Simone Amorim
A Inclusão de Mulheres no Mercado de Tecnologia
simoneas02
0
60
Get start with react-test-library.
simoneas02
0
55
ES6 and Beyond pdf
simoneas02
0
180
Montando layouts em um mini game
simoneas02
2
250
Experiência na China Simone e Willany pareando <3
simoneas02
0
79
Front-end na vida real
simoneas02
0
210
It's me!!
simoneas02
0
96
Montando layouts em um mini game chamado Browser
simoneas02
1
190
It's me!!
simoneas02
0
250
Other Decks in Technology
See All in Technology
松尾研LLM講座2025 応用編Day3「軽量化」 講義資料
aratako
8
4.2k
Building Serverless AI Memory with Mastra × AWS
vvatanabe
0
600
Claude Skillsの テスト業務での活用事例
moritamasami
1
110
フィッシュボウルのやり方 / How to do a fishbowl
pauli
2
390
Amazon Quick Suite で始める手軽な AI エージェント
shimy
2
1.9k
ActiveJobUpdates
igaiga
1
320
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
9.9k
Kiro を用いたペアプロのススメ
taikis
4
1.9k
MySQLのSpatial(GIS)機能をもっと充実させたい ~ MyNA望年会2025LT
sakaik
0
130
『君の名は』と聞く君の名は。 / Your name, you who asks for mine.
nttcom
1
120
AIエージェント開発と活用を加速するワークフロー自動生成への挑戦
shibuiwilliam
5
870
Strands AgentsとNova 2 SonicでS2Sを実践してみた
yama3133
1
1.9k
Featured
See All Featured
B2B Lead Gen: Tactics, Traps & Triumph
marketingsoph
0
33
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
410
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
Heart Work Chapter 1 - Part 1
lfama
PRO
3
35k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.2k
Code Reviewing Like a Champion
maltzj
527
40k
How to Think Like a Performance Engineer
csswizardry
28
2.4k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
61
50k
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
31
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
860
Transcript
A long time ago in a galaxy far far away…
Revenge of the Platform
I'm Simone Amorim, mother and studing for become a Front-End
Developer and CSS Evangelist <3 I love running and ride a bike! @simoneas02
http://www.w3.org/TR/css-variables/ CSS Custom Properties for Cascading Variables Module Level 1
Basics
Declare the Custom Properties .luke { --color: #000; --size: 200px;
}
Use with var() function .luke { --color: #000; --size: 200px;
background-color: var(--color); width: var(-size); height: var(-size); }
None
SCope
.container { --color: #000; } .box { background-color: var(—cor); }
// Bad <div class=“container”> O choose </div> <div class=“box”> You </div>
.container { --color: #000; } .box { background-color: var(—cor); }
// Good <div class=“container”> <div class=“box”> I choose You </div> </div>
:root { --cor: #000; } .luke { background-color: var(—cor); }
.leia { background-color: var(—cor); } // Good
FALLBACK
Use a second value .yoda { background-color: var(—color, green); width:
var(-size, 10px); height: var(-size, 10px); }
preprocessors x custom properties
Javascript
http://codepen.io/danield770/pen/rxqPOM
Support
http://caniuse.com/#search=variables
None
progressive enhancement
Double property trick .yoda { color: green; color: var(—color, green);
}
None
Para finalizar, o mais importante!
Código é só código, o que realmente importa é o
que o "codar" pode proporcionar para as pessoas que você ama.. “ - Afonso Pacifer
26 days Front-End Study
May the force be with you…
Thanks @simoneas02