How To Use Variables in CSS without SASS or LESS in 10 Minutes or Less

  Рет қаралды 4,898

IAmTimCorey

IAmTimCorey

Күн бұрын

Пікірлер: 36
@jesusdelarua5995
@jesusdelarua5995 11 ай бұрын
Thank you Tim. I always learn something new from your videos.
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Glad to hear it.
@RioTheHitman
@RioTheHitman 11 ай бұрын
This is awesome Im glad they added this
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
I’m glad you like them.
@andergarcia1115
@andergarcia1115 11 ай бұрын
Thanks Master, your way of teaching is the best
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
You are welcome.
@jayvyas1342
@jayvyas1342 10 ай бұрын
Great Tim. Learn something new, Thanks you!
@IAmTimCorey
@IAmTimCorey 10 ай бұрын
You are welcome.
@nickysmusic4592
@nickysmusic4592 11 ай бұрын
Great video, how did you get VScode and your web browswer to work in sync?
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
I use a plug-in called Live Server.
@richardnesh5919
@richardnesh5919 11 ай бұрын
Excellent info. Nice to see you using VS Code.
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Thanks!
@webluke
@webluke 11 ай бұрын
It wasn't directly mentioned, but I am guessing you can put all kinds of variable values, let that be a color, font, size, or other var(--variable)?
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Yep.
@vikikroft7228
@vikikroft7228 11 ай бұрын
Thank you Tim. Tim how to start CRM systems.
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
The place you start is by building LOTS of smaller applications. Trying to build a CRM system is like saying "I want to fly a rocket to the moon" as your first flight ever. It is really complicated.
@TheProfessionalGamerSS4444
@TheProfessionalGamerSS4444 10 ай бұрын
Is it possible to change the variable dynamically using JavaScript? I’m thinking like what if you provided a control on your website to change the color and the user change the color and you wanted it to go in your style variable so it could affect the whole site.
@IAmTimCorey
@IAmTimCorey 10 ай бұрын
Yes, you can do that.
@waynehawkins654
@waynehawkins654 10 ай бұрын
Nice. What about storing in a C# string and change at run time in a Blazor Razor page. Can we do this?
@IAmTimCorey
@IAmTimCorey 10 ай бұрын
I don't know that you could do this. However, you could apply classes that would essentially do the same thing if you want.
@davidschinsing8789
@davidschinsing8789 11 ай бұрын
Nice!
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Thanks!
@shaiarocks
@shaiarocks 11 ай бұрын
":root" is a css keyword? Can I have other css variable sections? maybe per page or something?
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Yep, root is a pseudo-class, which means it effectively makes the variables into global variables. And yes, they can cascade like anything else in CSS, so you can define them at any level or re-define them at any level. There are a lot of things like this in CSS3 that people aren't aware of. Same with HTML5. That's why I spent so much time in the Web Development Mastercourse covering topics like this. HTML and CSS have changed a lot in the past few years.
@AabirKashif
@AabirKashif 11 ай бұрын
Awesome!
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Thanks!
@VeaceslavBARBARII
@VeaceslavBARBARII 11 ай бұрын
I'm wondering if there's a tool that would convert SASS/SCSS variables into CSS ones for me, so that I could leverage static analysis on SASS variables yet have the flexibility of dynamically modifying CSS variables using JavaScript.
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
What can you do with an SCSS variable that CSS variables don’t provide? You could even mix the two if needed but I’ve never seen the use case for that.
@RioTheHitman
@RioTheHitman 11 ай бұрын
Is there any loops available?
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
I would encourage you not to treat CSS like a programming language. It is a styling language.
@Caipa-b6i
@Caipa-b6i 11 ай бұрын
Please use less sass in video titles. Thanks for the video, a nifty trick i will use.
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
You are welcome. And I’m assuming the SASS comment is a joke.
@nested9301
@nested9301 11 ай бұрын
hmm you are doing css now 😶
@IAmTimCorey
@IAmTimCorey 11 ай бұрын
Yep. I cover the supporting technologies around C# and the web is a big one.
@mikebreeden6071
@mikebreeden6071 11 ай бұрын
He does it all 😁
@jeffsherman9638
@jeffsherman9638 11 ай бұрын
First time I heard of variables in CSS
How IDisposable and Using Statements Work Together in C#
10:01
IAmTimCorey
Рет қаралды 33 М.
Variables in CSS - Level Up variables with Propery
10:21
Lun Dev
Рет қаралды 39 М.
UFC 310 : Рахмонов VS Мачадо Гэрри
05:00
Setanta Sports UFC
Рет қаралды 1,2 МЛН
Гениальное изобретение из обычного стаканчика!
00:31
Лютая физика | Олимпиадная физика
Рет қаралды 4,8 МЛН
We Attempted The Impossible 😱
00:54
Topper Guild
Рет қаралды 56 МЛН
99.9% IMPOSSIBLE
00:24
STORROR
Рет қаралды 31 МЛН
Using CSS custom properties like this is a waste
16:12
Kevin Powell
Рет қаралды 185 М.
CSS Isolation in Blazor Applications in 10 Minutes or Less
9:49
IAmTimCorey
Рет қаралды 10 М.
Learn CSS Variables In 7 Minutes
7:20
Slaying The Dragon
Рет қаралды 50 М.
CSS Variables - CSS vs Sass - variables inside media queries
6:04
Kevin Powell
Рет қаралды 27 М.
Web Developers Are Disconnected
21:36
ThePrimeTime
Рет қаралды 232 М.
Real 10x Programmers Are SLOW To Write Code
14:51
Thriving Technologist
Рет қаралды 69 М.
CSS Переменные | CSS Variables | функция var()
10:48
Александр Ламков — Friendly Frontend
Рет қаралды 6 М.
The differences between CSS and Sass Nesting
12:12
Kevin Powell
Рет қаралды 31 М.
The Dictionary Data Structure in C# in 10 Minutes or Less
10:20
IAmTimCorey
Рет қаралды 42 М.
UFC 310 : Рахмонов VS Мачадо Гэрри
05:00
Setanta Sports UFC
Рет қаралды 1,2 МЛН