Sha256: cad9f37c520c15915b189a093c861bd815e156b102ec8096256b96aca00b4457
Contents?: true
Size: 546 Bytes
Versions: 33
Compression:
Stored size: 546 Bytes
Contents
# frozen_string_literal: true module Bridgetown module Utils module RubyExec def self.search_data_for_ruby_code(convertible) return if convertible.data.empty? # Iterate using `keys` here so inline Ruby script can add new data keys # if necessary without an error data_keys = convertible.data.keys data_keys.each do |k| v = convertible.data[k] next unless v.is_a?(Proc) convertible.data[k] = convertible.instance_exec(&v) end end end end end
Version data entries
33 entries across 33 versions & 1 rubygems