Skip to content

Offer a deep linking solution for the News toolkit #1582

@Piinks

Description

@Piinks

Original: flutter/flutter#154508


Use case

As an active user of the News Toolkit, I’ve used it twice, and on both occasions, clients specifically requested the implementation of a deep linking solution. In my experience, deep linking is an essential feature for news applications to enhance user engagement and provide a seamless user experience. A common scenario is when a user shares a link to a news article, but instead of opening directly in the app, the link redirects to the web, even if the app is installed. I believe adding deep linking functionality would increase the value of the toolkit.

Proposal

This feature request stems from an existing PR I created for the News Toolkit. The toolkit currently uses Firebase Dynamic Links to handle sign-in with email links. However, with the announcement that Dynamic Links are being deprecated, I created a PR that adds an abstraction for the deep link client, DeepLinkClient, and implements this abstraction using the current Dynamic Links setup. The abstraction would enable an easy transition from Dynamic Links to a new solution.

But then Firebase communicated that this functionality will be replaced, not deprecated. Still, adding the abstraction could be a first step toward integrating deep link handling into the toolkit.

My proposal is to build on top of the existing PR (#1158) and implement the simplest form of deep link handling for the News Toolkit: opening a news article based on the link that opened the app. The most common scenario would involve extracting the slug from the link, which is usually the string following the last forward slash. For example:

https://blog.google/technology/ai/google-io-2024-100-announcements/

The slug for this link would be google-io-2024-100-announcements.

The initial scope of this feature would be to extract the slug from the link and add a search by slug API to the dart frog server.

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