Generators

TypeScript Browser SDK

Source code

Latest version: 0.9.5

The TypeScript Browser SDK generator outputs a fully functional TypeScript/JavaScript SDK for usage in the browser. It can publish the SDK to npmjs.org (or any other Node package repository).

Local

1
2
3
4
5
6
7
8
groups:
  local:
    generators:
      - name: fernapi/fern-typescript-browser-sdk
        version: 0.9.5
        output:
          location: local-file-system
          path: ../generated/sdk/browser

Publish an internal package

Publish the generated SDK to a private NPM hosted by Fern. Available on the Starter plan.

1
2
3
4
5
6
7
8
groups:
  internal:
    generators:
      - name: fernapi/fern-typescript-browser-sdk
        version: 0.8.13
        output:
          location: npm.buildwithfern.com
          package-name: "@fern-imdb/api" # replace imdb with your org name

Publish a public package

1
2
3
4
5
6
7
8
9
10
groups:
  publish:
    generators:
      - name: fernapi/fern-typescript-browser-sdk
        version: 0.9.5
        output:
          location: npm
          package-name: imdb-browser # replace imdb with your package name
        github:
          repository: imdb/imdb-browser # replace imdb with your org & package name

Configuration options

You can customize the behavior of the TypeScript Browser generator in generators.yml. The options available are identical to the options for the TypeScript Node generator.