Module: VizBuilder::Helpers
- Defined in:
- lib/vizbuilder.rb
Overview
The Helpers module holds methods that are added to both the config and template contexts. So you can use these in the config block and in templates.
Instance Method Summary collapse
-
#build? ⇒ Boolean
Are we building this app out?.
-
#development? ⇒ Boolean
Is this in development?.
-
#production? ⇒ Boolean
Is this in production?.
-
#server? ⇒ Boolean
Are we running as a server?.
Instance Method Details
#build? ⇒ Boolean
Are we building this app out?
349 350 351 |
# File 'lib/vizbuilder.rb', line 349 def build? config[:mode] == :build end |
#development? ⇒ Boolean
Is this in development?
359 360 361 |
# File 'lib/vizbuilder.rb', line 359 def development? config[:target] == :development end |
#production? ⇒ Boolean
Is this in production?
354 355 356 |
# File 'lib/vizbuilder.rb', line 354 def production? config[:target] == :production end |
#server? ⇒ Boolean
Are we running as a server?
344 345 346 |
# File 'lib/vizbuilder.rb', line 344 def server? config[:mode] == :server end |