How to use macaca-datahub - 1 common examples

To help you get started, we’ve selected a few macaca-datahub 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 umijs / umi / packages / umi-plugin-datahub / src / index.js View on Github external
export default (api, opts = {}) => {
  const datahubConfig = {
    port: 5678,
    hostname: '127.0.0.1',
    store: join(__dirname, 'data'),
    proxy: {},
    showBoard: false,
    ...opts,
  };

  const defaultDatahub = new DataHub({
    port: datahubConfig.port,
  });

  api.register('beforeServerWithApp', ({ args: { app } }) => {
    datahubMiddleware(app)(datahubConfig);
    defaultDatahub.startServer(datahubConfig).then(() => {
      console.log('datahub ready');
    });
  });
};

macaca-datahub

Continuous data provider for development, testing, staging and production.

MIT
Latest version published 2 years ago

Package Health Score

48 / 100
Full package analysis

Popular macaca-datahub functions

Similar packages