module Kernel
Public Instance Methods
require_relative(path)
click to toggle source
# File packages/gems/js/lib/js/require_remote/relative_shim.rb, line 6 def require_relative(path) caller_path = caller_locations(1, 1).first.absolute_path || '' dir = File.dirname(caller_path) file = File.absolute_path(path, dir) original_require_relative(file) rescue LoadError JS::RequireRemote.instance.load(path) end
Also aliased as: original_require_relative