# Function replaceInline

- replaceInline(replacedElem: HTMLElement, newElem: HTMLElement): void

  Replaces the attributes and child elements of an existing element (`replacedElem`) with those of a new element (`newElem`), while keeping the original reference.

  #### Parameters

  - replacedElem: HTMLElement

    The element to be replaced (its content and attributes will be updated).

  - newElem: HTMLElement

    The element providing the new attributes and content.

  #### Returns void

  - Defined in src/shared/utils.js:1185