How to use the tweek-client.createTweekManagementClient function in tweek-client

To help you get started, we’ve selected a few tweek-client examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Soluto / tweek / services / editor / src / utils / tweekClients.js View on Github external
/* global window */
import { createTweekClient, createTweekManagementClient } from 'tweek-client';
import { retrieveToken } from '../services/auth-service';

export const getGatewayBaseUrl = () => window.GATEWAY_URL || '';

const config = {
  baseServiceUrl: getGatewayBaseUrl(),
  getAuthenticationToken: retrieveToken,
};

export const tweekManagementClient = createTweekManagementClient({config, requestTimeoutInMillis: 60 * 1000 });

export const tweekClient = createTweekClient(config);

tweek-client

Tweek client for JavaScript

MIT
Latest version published 3 years ago

Package Health Score

48 / 100
Full package analysis

Similar packages