2 ms·
I would have hoped that it uses CSS logic. Should be doable? I am not a CSS wizard (still look up things on the fly), but I think there are rules for "if class
by Tichy 17y ago
I would have hoped that it uses CSS logic. Should be doable? I am not a CSS wizard (still look up things on the fly), but I think there are rules for "if class x is below class y in the hierarchy then..." and for selected and unselected links. Perhaps that is sufficient to create a much more compressed CSS only Tic Tac Toe?
- pmjordan 17y agoI suspect this to be between difficult and impossible to do as CSS doesn't have any way of knowing the past; I don't think there's a way to remember moves as such. All I can think of is to somehow have an #anchor for each possible configuration and to select the visible links for the next move depending on which anchor is active. This isn't really any more elegant than having a separate page for each configuration; you're not encoding any actual logic in the CSS, just the graph of possible outcomes.
- Tichy 17y agoNot really encoding logic, true - but perhaps a more compressed representation would be possible. I am not sure one would have to list every possible configuration.