Skip to content

Commit b369312

Browse files
authored
Update index.ts (#4136)
1 parent e30ce4a commit b369312

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

assets/js/phoenix_live_view/index.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,10 @@ const LiveSocket = OriginalLiveSocket as unknown as LiveSocketConstructor;
317317
* which is triggered after the element has been added to the DOM. If you try
318318
* to call `createHook` from the constructor, an error will be logged.
319319
*
320+
* Furthermore, you can only start using the hook's APIs after the `mounted`
321+
* callback of the hook has been called. If you try to call them earlier,
322+
* an error will be logged.
323+
*
320324
* @example
321325
*
322326
* class MyComponent extends HTMLElement {

0 commit comments

Comments
 (0)