Access configuration values in new platform plugin

I have defined a visualization plugin for the new platform currently running on Kibana 7.8.2 (github version). Now I have realized I need to let users enter some configuration values in order to make the usage more dynamic. The question is just how I access this information.

I have defined a configuration schema for my plugin in config.ts

import { schema, TypeOf } from '@kbn/config-schema';

export const configSchema = schema.object({
    enabled: schema.boolean({ defaultValue: true }),
    dateformats: schema.object({ key: schema.string(), value: schema.string() })
});

This is as far as I have come. I do not understand where I should "register" this schema, and also where I later in my visualization component can access this value.

I think the best documented information is in the migration guide here: https://github.com/elastic/kibana/blob/master/src/core/MIGRATION.md#configure-plugin

You can check this example if it can help you.
You need to provide a compoenent (or html if you use BaseViz) that will capture user input (Options Tab), like this

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.