Programmatically change the content of the file field

And can I just expand the field. Around the same way I can do this in a .js file?

panel.plugin("your/plugin", {
  fields: {
    hello: {
      extends: "k-text-field"
    }
  }
});

Or I can ask the question for https://forum.getkirby.com/u/bastianallgeier/summary ?