Skip to Main Content
Status Backlog
Created by Guest
Created on Feb 28, 2024

Front Chat SDK as NPM package with TypeScript

Problem
Integrating Front Chat with verified identity is difficult; there's no NPM package or TypeScript support, making it easy for developers to send data in the wrong format.

Request
Publish Front Chat as an NPM package with TypeScript definitions to streamline integration, especially for React apps.

  • Attach files
  • Guest
    Jul 29, 2024

    This comment was adapted from this GitHub issue: https://github.com/frontapp/front-chat-sdk/issues/10#issuecomment-2244286658

    Please consider creating an NPM package. It's very rare for a first-party package like this to not be released on NPM, and it means that we need to add a reference to this GitHub repo in our `package.json` manifest. Here are the issues as I see them:

    1. This is non-standard, meaning we'll need to obtain additional exemptions from our security teams to install from a repository directly;

    2. This has poor control over version management, as the best we can do is pin a specific commit in this repository's history;

    3. The repository has development files and a dangling example app that certainly don't need to be present in production environments.

    I would instead propose following Stripe's methodology, where they let you install their bootstrap packages from NPM (which has first-class support for scanning by organizations like Snyk), but their code internals then later load a dynamic bundle from their CDN.