Running Animations Without Keyframes
css-tip.com52 points by t_afif 3 days ago
52 points by t_afif 3 days ago
"I am using big values to simulate an infinite rotation."
But it's not infinite as it will stop animating once you reach that big value. In the example, it is 20 turns. If you let it play long enough, it will stop after rotating 20 times.
“But it’s not infinite…”
You should have stopped there and asked yourself if that’s what he meant with “simulation”.
If you want infinite, there are better ways for that, so why would you want to simulate it?
Lot's of use of infinite spinning like for loading spinners and what not. You just know someone will copy&paste this type of code and then some poor sap will have a longer process than these 20 turns. Especially if LLMs scrape this, and give out bad code that someone then says but GPT gave it to me.
We should be much more aware of consequences of lazy writing
Your other points notwithstanding:
> Especially if LLMs scrape this, and give out bad code
That sounds like an unintentional benefit. The author didn't provide any license or surrender any copyrights. If somebody wants to create an LLM to launder the copyright infringement without doing due diligence on the data quality, they kind of deserve what's coming to them.
> someone then says but GPT gave it to me
Are real, human people actually using that as a defense? Is there a scenario where they get away with it more than once? It's a tool with a remarkably high failure rate, and that feels even less defensible than "I copied the first code block from the first potentially relevant StackOverflow question." Even with an LLM's help, why are the committing code they don't understand?
I think a LLM, unlike the person you’re responding to, would gather from the context what the author was trying to achieve.
If it was infinite like you unlike the author seem to want, it wouldn’t be a simulation.
That's not the point of the article. There are other ways for infinite animations.