How to use @skyux/theme - 4 common examples

To help you get started, we’ve selected a few @skyux/theme 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 blackbaud / skyux-builder / config / karma / dev-src-app.karma.conf.js View on Github external
webpackConfig.plugins.unshift(
    new DefinePlugin({
      'ROOT_DIR': JSON.stringify(srcPath)
    })
  );

  // Adjust the loader src path.
  webpackConfig.module.rules[webpackConfig.module.rules.length - 1].include = srcPath;

  // This is needed exclusively for internal runtime unit tests,
  // which is why it's here instead of alias-builder or the shared test.webpack.config.js
  // It's relative from src/app/
  webpackConfig.resolve.alias['@blackbaud/skyux-builder/runtime'] = runtimePath;

  // Instead of adding skyux2 as a dependency of skyux-builder
  webpackConfig.resolve.alias['@skyux/theme/css/sky.css'] =
    '../../utils/runtime-test-skyux.css';

  // Remove sky-style-loader
  delete config.preprocessors['../../utils/spec-styles.js'];
  config.files.pop();

  config.set({
    webpack: webpackConfig,
    coverageReporter: {
      dir: path.join(process.cwd(), 'coverage', 'src-app')
    }
  });
}
github blackbaud / skyux-builder / config / webpack / alias-builder.js View on Github external
buildAliasList: function (skyPagesConfig, argv) {
    let alias = {
      'sky-pages-spa/src': spaPath('src'),
      'sky-pages-internal/runtime': outPath('runtime')
    };

    // Order here is very important; the more specific CSS alias must go before
    // the more generic dist one.
    if (skyPagesConfig.skyux.cssPath) {
      alias['@skyux/theme/css/sky.css'] = spaPath(skyPagesConfig.skyux.cssPath);
    }

    if (skyPagesConfig.skyux.importPath) {
      alias['@blackbaud/skyux/dist'] = spaPath(skyPagesConfig.skyux.importPath);
    }

    // Allow SPAs to provide custom module aliases.
    const moduleAliases = skyPagesConfig.skyux.moduleAliases;
    if (moduleAliases) {
      const command = (argv && argv.command) ? argv.command : 'serve';

      Object.keys(moduleAliases).forEach((key) => {
        if (command === 'serve') {
          alias[key] = spaPath(moduleAliases[key]);
        } else {
          alias[key] = skyPagesConfigUtil.spaPathTemp(moduleAliases[key]);
github blackbaud / skyux-builder / test / config-webpack-common.spec.js View on Github external
expect(
      alias['@blackbaud/skyux/dist']
    ).toBe(path.join(process.cwd(), importPath));

    config = lib.getWebpackConfig({
      runtime: runtimeUtils.getDefaultRuntime(),
      skyux: {
        mode: 'advanced',
        cssPath: cssPath
      }
    });

    alias = config.resolve.alias;

    expect(
      alias['@skyux/theme/css/sky.css']
    ).toBe(path.join(process.cwd(), cssPath));
  });
github blackbaud / skyux2 / config / utils / spec-styles.js View on Github external
beforeAll(function (done) {
    styleLoader.loadStyles().then(done);
  });
}());

@skyux/theme

This library was generated with [Nx](https://nx.dev).

MIT
Latest version published 2 days ago

Package Health Score

78 / 100
Full package analysis