# frozen_string_literal: true # Helps build a list of conditional class names module Ariadne # :nodoc: module ClassNameHelper def merge_class_names(*args) [].tap do |classes| args.each do |class_name| next if class_name.blank? case class_name when String classes << class_name else raise ArgumentError, "Expected String class name, got #{class_name.class}" end end end.join(" ") end end end