class ViteRuby::Config

def config_from_file(path, mode:)

Internal: Loads the configuration options provided in a JSON file.
def config_from_file(path, mode:)
  multi_env_config = load_json(path)
  multi_env_config.fetch('all', {})
    .merge(multi_env_config.fetch(mode, {}))
rescue Errno::ENOENT => error
  warn "Check that your vite.json configuration file is available in the load path:\n\n\t#{ error.message }\n\n"
  {}
end