RocketChat / RocketChat/Rocket.Chat.ReactNative

feature request: migrate deepLinking saga from JavaScript to TypeScript

Open
#7,090 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

type: feature
Dominant language
TypeScript
Stars
2.4k
Forks
1.5k
Avg merge
1d 18h
Merged PRs (30d)
90

Description

Feature Description

app/sagas/deepLinking.js is the only saga in the codebase still written in plain JavaScript. Every other saga, action, and utility in the navigation and deep-linking pipeline has already been migrated to TypeScript — but this file was left behind.

This means the most critical routing saga in the app — handling all deep links, push notification routing, server switching, OAuth, and share extension flows — has zero type safety.

Specific gaps:

  • params.type, params.rid, params.host, params.path are all untyped
  • roomTypes mapping object has no typed keys or values
  • Generator functions navigate(), handleOpen(), handleOAuth(), handleInviteLink() have no typed parameters or return types
  • Errors from passing the wrong params shape are silently swallowed at runtime
Motivation and Use Case
  • Runtime errors in deep link / push notification routing become invisible until they reach users
  • Makes it harder to safely refactor navigation structure — any change to this file can't be validated by the compiler
  • Inconsistent with the rest of the codebase which is fully typed
  • Adding a typed IDeepLinkParams interface will immediately surface any misuse at compile time
Additional Context

This file is directly involved in push notification routing and deep link handling. Having it typed will make future navigation work (e.g. any navigation restructuring) safer and compiler-validated.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading app/sagas/deepLinking.js and comparing it with the already migrated TypeScript sagas, actions, and utilities in the navigation and deep-linking pipeline. Review navigate(), handleOpen(), handleOAuth(), and handleInviteLink(), along with the roomTypes mapping and deep-link parameter usage. Done means this saga is TypeScript with typed parameters, generator returns, mappings, and an IDeepLinkParams interface covering the listed flows.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native, typescript
Domain
mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.