Make the formula api optional for the lens builder (#179255)

## Summary

For ES|QL charts the formula api should be redundant. This is going to
make the api lighter as there is no need to import the lens plugin if
you want to use the builder to create ES|QL charts.
This commit is contained in:
Stratoula Kalafateli 2024-03-25 15:09:37 +01:00 committed by GitHub
parent e551625ade
commit 10e34e4723
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
26 changed files with 31 additions and 30 deletions

View file

@ -60,7 +60,7 @@ const tableConfig: LensConfig = {
],
value: 'bytes',
};
const configBuilder = new LensConfigBuilder(lensFormulaAPI, dataViewsAPI);
const configBuilder = new LensConfigBuilder(dataViewsAPI, lensFormulaAPI);
const lensConfig = configBuilder.build(tableConfig, {
timeRange: { from: 'now-1y', to: 'now', type: 'relative' },
embeddable: true,