crouter
crouter copied to clipboard
Routes are not evaluated in the context of the enclosing class
Example:
class RouterExample < Crouter::Router
@instance_var = ""
post "/" do
@instance_var # Compiler error: "can't use instance variables at the top level"
end
end
I'm having the same problem too. I'm new to Crystal/Ruby, I don't know much detail but what is the status of this issue? Is this ever going to be resolved?