VFG Display Fields is a Vue.js component for displaying the fields of an object - using a vue-form-generator (vfg) schema if provided.
Note that development of this package has been abandoned as the author is retiring. It nearly works but see this issue. For a half-experienced developer it should be easy to resolve. If you would like to take ownership, feel free to do so (contact peter@pcooper.me.uk).
- (with a schema) display of core and optional vfg field types in an appropriate way
- (without a schema) display of all simple fields as strings
- customizable styles
- options include whether to show null values, and hiding particular fields
- VFG custom fields, including Public Custom Fields
I have a mapping application (Mapping for One-Place Studies - M4OPS) that stores information about features, and needs to display them on hover or click. In my new version of this I am using vfg schemas to define the structure of this information, and allowing users to define it. VFG Display Fields can display everything entered.
- vue-form-generator
- fecha
- tinycolor2
- lodash
npm install vfg-display-fields
<display-fields
:schema="schema"
:obj="model"
:options="options"
/>
//
// You can register a component manually
//
import { DisplayFields } from 'vfg-display-fields';
export default {
...
components: {
'display-fields': DisplayFields
},
...
};
vfg-display-fields is available under the MIT license.
Copyright (C) 2019 PeterC66