V
V
Viktor Vsk2014-03-10 01:24:39
ruby
Viktor Vsk, 2014-03-10 01:24:39

How to organize caching [of code, classes] in ruby ​​(without rails)?

Tell me, what do you think, the problem is in the environment or in the approach. I use the Spar
gem . Its meaning is that it starts the server through rack. in the haml file I write Time.now (also tried different variations: Proc.new { Time.now }.call, lambda { Time.now }.call ... ) and the same information is displayed until or reload server, or write another code in that place, reload the page, return the old one. The example with Time.now is taken for abstraction - initially I tried to add my own classes from external files. The gem is not particularly supported and, perhaps, of high quality, but it is quite suitable for small tasks, I would like to understand how to expand it correctly, it seems that the question is basic and obvious.
I hope I made the point clear. If I confuse something with concepts, correct me.
PS It's quite interesting that finding information on ruby ​​without rails is hard, as it seemed to me.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question