3.2.1 • Published 2 years ago

@transfix/airhorn v3.2.1

Weekly downloads
96
License
ISC
Repository
github
Last release
2 years ago

Airhorn

Front end javascript version of the Transfix logging library. For more info, see the airhorn repo.

Use Airhorn in your project

  1. Install the package

    npm i @transfix/airhorn
  2. Import datadog in your index.html:

    <script type="text/javascript" src="https://www.datadoghq-browser-agent.com/datadog-logs-us.js"></script>
    <script>
      // Set your client token
      DD_LOGS.init({
        clientToken: '<CLIENT_TOKEN>',
        forwardErrorsToLogs: true,
    });
    </script>

    See the datadog docs for more info.

  3. Add a call to airhorn.configure somewhere in your app:

    airhorn.configure({ appName: 'some-app', environment: 'staging', sentryDSN: '<SENTRY_KEY>' })

    The environment argument is typically something like test, staging, or production.

Publishing to the private Transfix npm account

The package is hosted at https://www.npmjs.com/package/@transfix/airhorn

The steps to update are:

  1. git commit your changes
  2. Get an npm readwrite token into your environment:

    export NPM_TOKEN=$(aws secretsmanager get-secret-value --secret-id=prod/npm/token | jq -r .SecretString)
  3. Bump the package version like so:

    For a patch release (bug fixes: v1.0.0 -> v1.0.1):

    npm run publish:airhorn:patch

    For a minor release (new features: v1.0.0 -> v1.1.0):

    npm run publish:airhorn:minor

    For a major release (breaking changes: v1.0.0 -> v2.0.0):

    npm run publish:airhorn:major
  4. This will build, update the version, and publish all at once!

3.2.1

2 years ago

3.2.0

2 years ago

3.0.0

3 years ago

2.1.4

4 years ago

2.1.3

4 years ago

2.1.2

4 years ago

2.1.1

4 years ago

2.1.0

4 years ago

2.0.0

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.1

4 years ago

1.0.2

5 years ago

1.0.0

5 years ago