Skip to content

App can't restart with path configuration #219

@ajdubovoy

Description

@ajdubovoy

Hi,

I'm building a new iOS app with turbo-navigator.

I have the following line:

  private lazy var navigator = TurboNavigator(pathConfiguration: pathConfiguration)
  private let pathConfiguration = PathConfiguration(sources: [
      .file(Bundle.main.url(forResource: "path-configuration", withExtension: "json")!),
      .server(URL(string: "\(rootURL)configurations/paths.json")!)
  ])

When I build and launch the app, it works totally fine and loads the path configuration successfully. But, when I try to close and reload the app (or rebuild it), I just get this:

CleanShot 2024-07-02 at 18 15 08@2x

And after a while in the console:

0x13201cc40 - [PID=49325] WebProcessProxy::didBecomeUnresponsive:

I also have a print statement before the homepage loads, and this does not get executed. So, it seems like turbo-ios doesn't even try to load the first page.

The error persists until I uninstall and rebuild the app, and then it works fine...until I build again or reopen.

I've found that it fixes fine when I change my code to:

private lazy var navigator = TurboNavigator()

So, I'm a bit baffled and wondering if there's a bug in turbo-ios with how it caches path configuration or something like that. Would greatly appreciate your help.

Thanks so much ❤️

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions