We don’t really have a design pattern for that but have you tried using a text field that uses loadOptions then in the loadOptions method read the file and return the contents?
It may not be possible but I think this would be the best way to check.
I think this could work. Then it would show the file as configured? But what about when I change the file path? Will loadOptions reload the configured properties, i.e. show the new content? What if the file changes on disk?
Another (slightly hacky) suggestion would be to use parameter hints. This is the small text that shows beneath some parameters.
The param hint could contain a link, that opens the file in a new tab (“Preview the file”). From there, browser extensions could handle formatting that file in a viewable way.
Sorry @haf - my focus at n8n is product design so was just speaking from a UX standpoint. I am not sure of the technical viability of my proposal. Apologies
They would need to reload the data if it is possible, It is just a theory at the moment to get around something we don’t currently have a direct option for. I really like the idea though as it could extend to CSV or JSON files if you were to load them as a config source for a workflow just to double check the data.