export default function feature(existing, id, options = {}) {
  if(!id) {
    return existing
  } 

  const settings = {
    ...((existing && existing[id]) || {}),
    ...options,
    id,
  }

  return {
    ...existing || {},
    [id]: settings,
  }
}
