Sha256: 4957c160786e51f302b2320c0115d32abfd50a7427e9df5339d955e7f5e6120a

Contents?: true

Size: 597 Bytes

Versions: 7

Compression:

Stored size: 597 Bytes

Contents

# frozen_string_literal: true

module RubyNPM
  module Options
    module Types
      class Standard < ImmutableStruct.new(
        :name,
        :value,
        :separator,
        :placement
      )
        def initialize(name, value, **opts)
          super(
            name:, value:,
            separator: opts[:separator],
            placement: opts[:placement]
          )
        end

        def apply(builder)
          builder.with_option(
            name,
            value.render,
            separator:,
            placement:
          )
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ruby_npm-0.2.0.pre.2 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.2.0.pre.1 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.1.0 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.1.0.pre.14 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.1.0.pre.13 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.1.0.pre.12 lib/ruby_npm/options/types/standard.rb
ruby_npm-0.1.0.pre.11 lib/ruby_npm/options/types/standard.rb