These are chat archives for SmartFocus/reactjs

20th
Feb 2015
Juho Vepsäläinen
@bebraw
Feb 20 2015 06:41
http://www.csstyle.io/ looks cool. what sort of css approach do you use?
Matt Bilbow
@mattbilbow
Feb 20 2015 09:59
LESS, but much like the above organised into modules that mirror our react components
Juho Vepsäläinen
@bebraw
Feb 20 2015 10:27
ok. apparently csstyle might support LESS some point in the future. there was talk about that in their issue tracker
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:28
i still am thinking about just declaring css in js
you can still have classes and other things
the only problem is hover state but that can also be handled in js too
hover / media states*
and other 'state' stuff
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:29
not even this, but just pure js and inline styles everywhere
Juho Vepsäläinen
@bebraw
Feb 20 2015 10:30
the problem is that css isn't just about styling. there's some logic there too
i like the idea of "tweaks" (class="button +rounded +glass") in csstyle
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:51
well yeah, but you can do something like
var roundedButton = Object.assign({}, button, rounded, glass);
just wrap it around a nice-looking function like
var roundedButton = s(button,rounded,glass); :P
Juho Vepsäläinen
@bebraw
Feb 20 2015 10:54
that's definitely true. maybe js driven approaches will make css as we know it look obsolete :)
Matt Bilbow
@mattbilbow
Feb 20 2015 10:55
Yeah at first I was like NO WAY! but if you actually spend some time planning the implementation instead of just writing and re-writing inline styles everywhere it could actually be quite nice.
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:55
but still what about states and media queries and such.... may need some thinking
Matt Bilbow
@mattbilbow
Feb 20 2015 10:55
Surely we don’t need media queries? As in JS we can know the device?
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:55
i guess you could do like roundedButon[":hover"] = s(glass); or something
yeah we can
depends if css is done before or after or at some other stage than js events
Matt Bilbow
@mattbilbow
Feb 20 2015 10:56
hmmm yeah
Firtina Ozbalikci
@toxicFork
Feb 20 2015 10:56
e.g. you resize the screen, does it do: set screen width, do css layouting, render contents, call js event in next tick?
even with css layouting it's slow look at anything that uses nwjs or even atom, resize the window and cringe
yeah try resizing this page right now by dragging the right side left and right
it takes like 2 frames for layout to catch up :D
i guess it's not the end of the world, but just a bit irritating
i can live with it though
Juho Vepsäläinen
@bebraw
Feb 20 2015 10:59
i wonder... could this sort of development lead to new layout models? ie. someone hacks new semantics on top of old, working ones
Juho Vepsäläinen
@bebraw
Feb 20 2015 11:06
Matt Bilbow
@mattbilbow
Feb 20 2015 11:07
I never managed to convince myself to try GSS
I do like the idea of the xcodey like relative positioning though
Firtina Ozbalikci
@toxicFork
Feb 20 2015 11:21
looks interesting
Matt Bilbow
@mattbilbow
Feb 20 2015 11:56
I think it’s made by the same people that are creating that AI type sitebuilder that seems to follow me around the web - thegrid.io
Firtina Ozbalikci
@toxicFork
Feb 20 2015 14:48
what's the correct way of implementing <select> with an optional value (e.g. null) in react? if i set value=null in the component it just thinks 'ok then i won't update the value any more' rather than 'pick the option whose value is not set'
Firtina Ozbalikci
@toxicFork
Feb 20 2015 16:09
ended up writing my custom indices -> values map and a 'null' value string :P
Tomczik76
@Tomczik76
Feb 20 2015 23:06
LOL GSS is by the grid
All I know about it is Pete Hunt was going to do a talk on it at React Conf and thought it was too much of disaster and did it on Full Stack Flux instead. I was stoked as styling is not my forte..