Sha256: 46511d4b6e3ab5a046faf106ef5106bb7b79131f8d46e81addfcf366c0605160

Contents?: true

Size: 428 Bytes

Versions: 28

Compression:

Stored size: 428 Bytes

Contents

module Preact
  module Component
    class Params
      include Native::Wrapper

      def method_missing(prop, *args, &block)
        %x{
          const p = #@native;
          if (typeof p[prop] === 'undefined') {
            prop = Opal.Preact.lower_camelize(prop);
            if (typeof p[prop] === 'undefined') { return nil; }
          }
          return p[prop];
        }
      end
    end
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
isomorfeus-preact-10.6.15 lib/preact/component/params.rb
isomorfeus-preact-10.6.14 lib/preact/component/params.rb
isomorfeus-preact-10.6.13 lib/preact/component/params.rb
isomorfeus-preact-10.6.12 lib/preact/component/params.rb
isomorfeus-preact-10.6.11 lib/preact/component/params.rb
isomorfeus-preact-10.6.10 lib/preact/component/params.rb
isomorfeus-preact-10.6.9 lib/preact/component/params.rb
isomorfeus-preact-10.6.8 lib/preact/component/params.rb
isomorfeus-preact-10.6.7 lib/preact/component/params.rb
isomorfeus-preact-10.6.6 lib/preact/component/params.rb
isomorfeus-preact-10.6.5 lib/preact/component/params.rb
isomorfeus-preact-10.6.4 lib/preact/component/params.rb
isomorfeus-preact-10.6.3 lib/preact/component/params.rb
isomorfeus-preact-10.6.2 lib/preact/component/params.rb
isomorfeus-preact-10.6.1 lib/preact/component/params.rb
isomorfeus-preact-10.6.0 lib/preact/component/params.rb
isomorfeus-preact-10.5.11 lib/preact/component/params.rb
isomorfeus-preact-10.5.10 lib/preact/component/params.rb
isomorfeus-preact-10.5.9 lib/preact/component/params.rb
isomorfeus-preact-10.5.8 lib/preact/component/params.rb