Skip to content

Commit

Permalink
Add changeset
Browse files Browse the repository at this point in the history
  • Loading branch information
lemonmade committed Dec 6, 2022
1 parent 3f12ce2 commit 367d314
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .changeset/loud-kangaroos-wash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
'@remote-ui/core': minor
'@remote-ui/htm': minor
'@remote-ui/mini-react': minor
'@remote-ui/react': minor
'@remote-ui/rpc': minor
'@remote-ui/testing': minor
'@remote-ui/traversal': minor
'@remote-ui/vue': minor
---

Added a number of methods that align more closely with the corresponding DOM API, and deprecated a few existing methods with overlapping functionality:

- `RemoteParent.appendChild` is deprecated, with a new `RemoteParent.append` API recommended instead. This new API matches the [`Element.append`](https://developer.mozilla.org/en-US/docs/Web/API/Element/append) DOM API: it allows you to pass multiple children, including strings that are converted to text nodes.
- `RemoteParent.insertChildBefore` is deprecated, with a new `RemoteParent.insertBefore` API recommended instead. This matches the [`Node.insertBefore`](https://developer.mozilla.org/en-US/docs/Web/API/Node/insertBefore) DOM API, including the fact that the second argument can be null (in which case, the method behaves the same as `append`
- `RemoteParent.replaceChildren` is new, and matches the [`Element.replaceChildren`](https://developer.mozilla.org/en-US/docs/Web/API/Element/replaceChildren) DOM API. It allows passing any number of children/ strings, and those are used to fully replace the existing children.
- `RemoteComponent.remove` and `RemoteText.remove` are new, and match the [`Element.remove`](https://developer.mozilla.org/en-US/docs/Web/API/Element/remove) DOM API.
- `RemoteText.updateText` is deprecated in favor of a new `RemoteText.update` method, which is a little shorter.

0 comments on commit 367d314

Please sign in to comment.