Skip to content

Incorrect typescript definition for afterPageLoad helper #485

@IvanMisnik

Description

@IvanMisnik

From the documentation afterPageLoad helper accepts callback

(page) => void

as an argument
see: https://www.routify.dev/docs/helpers#after-page-load

but I see an error

Error: Argument of type '(page: ClientNodeApi) => void' is not assignable to parameter of type '(page?: ClientNodeApi) => boolean'.
  Type 'void' is not assignable to type 'boolean'. (ts)

version
Routify: 2.18.8
Svelte: 3.50.1

screenshot
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions