File Field

This component represents a field for uploading a file.

Configuration

For general configuration options, see General component configuration.

Specific configuration

value (string)

Content of the file in Base64-encoded string. See also Binding attributes of form components

Example

filefield.json
{
  "metaData": {
    "author": "Virtimo AG",
    "name": "Live PReview Form",
    "id": 999999,
    "version": 1
  },
  "components": [
    {
      "layout": "vertical",
      "components": [
        {
          "id": "file-upload",
          "label": "Upload your file here",
          "type": "filefield",
          "value": "/data/fileBase64"
        },
        {
          "id": "submit",
          "label": "Submit",
          "type": "button",
          "action": "submit"
        }
      ],
      "type": "container"
    }
  ],
  "dataSchema": {},
  "configuration": {
    "defaultLanguage": "de",
    "submitUrl": "http://localhost:3000/foo"
  },
  "state": {
    "data": {},
    "language": "de"
  }
}
Embedded preview

Keywords: