module PoiseJavascript::JavascriptCommandMixin::Resource

Mixin for resources which run Javascript commands.

Private Instance Methods

default_npm_binary() click to toggle source

Find the default gem binary. If there is a parent use that, otherwise use the same logic as {PoiseRuby::RubyProviders::Base#npm_binary}.

@return [String]

# File lib/poise_javascript/javascript_command_mixin.rb, line 43
def default_npm_binary
  if parent_javascript
    parent_javascript.npm_binary
  else
    ::File.expand_path('../npm', javascript)
  end
end