Sha256: b873a4e99816d826ac04b50ca4d6ad7ae2bf14f7dd2abfe3813eba9aad6706c0
Contents?: true
Size: 477 Bytes
Versions: 12
Compression:
Stored size: 477 Bytes
Contents
module Coprl::Presenters::WebClient::Helpers::Rails module LocalVariables # A rails specific helper to see if a local variable is defined # This passes the binding from the evaluating (erb) context # We don't do this inline, because rails and sintra have different variable names for the same thing def bound_locals_include?(variable, __binding__) locals = __binding__.local_variable_get(:local_assigns) locals.include? variable end end end
Version data entries
12 entries across 12 versions & 1 rubygems