Here is original function: https://github.com/npmx-dev/npmx.dev/blob/16988d8d1b1d79bccfa4a1c5c7b21a440ddd324f/app/pages/search.vue#L483-L488 And this one: https://github.com/npmx-dev/npmx.dev/blob/16988d8d1b1d79bccfa4a1c5c7b21a440ddd324f/app/app.vue#L67-L74 They should use SearchBox's (already exposed) `useTemplateRef('searchBoxRef').focus` method. Ref: https://github.com/npmx-dev/npmx.dev/pull/3214#discussion_r3889350009 Usage examples: https://github.com/npmx-dev/npmx.dev/blob/16988d8d1b1d79bccfa4a1c5c7b21a440ddd324f/app/components/AppHeader.vue#L177 https://github.com/npmx-dev/npmx.dev/blob/16988d8d1b1d79bccfa4a1c5c7b21a440ddd324f/app/components/AppHeader.vue#L187
Activity