Back to Kibana

@kbn/elastic-assistant-common

x-pack/platform/packages/shared/kbn-elastic-assistant-common/README.md

9.4.01.5 KB
Original Source

@kbn/elastic-assistant-common

This package provides common code consumed in both the browser, i.e. the platform/packages/shared/kbn-elastic-assistant package and solutions/security/plugins/security_solution plugin, and on the server, i.e. the solutions/security/plugins/elastic_assistant plugin.

For example, the data anonymization functions exported by this package are be used in both the browser, and on the server.

Maintainers

Maintained by the Security Solution team

Running unit tests with code coverage

To (interactively) run unit tests with code coverage, run the following command:

sh
cd $KIBANA_HOME && node scripts/jest --watch x-pack/platform/packages/shared/kbn-elastic-assistant-common --coverage

OpenAPI Codegen

Implemented using the new OpenAPI codegen and bundle packages:

To run codegen/bundling locally, cd to x-pack/platform/packages/shared/kbn-elastic-assistant-common/ and run any of the following commands:

bash
yarn openapi:generate
yarn openapi:generate:debug
yarn openapi:bundle

Codegen is configured to run on CI by means of the .buildkite/scripts/steps/code_generation/elastic_assistant_codegen.sh script, which is run as part of the checks pipeline, and is registered in .buildkite/scripts/steps/checks.sh.