Package Exports
- vue-object-view
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (vue-object-view) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
vue-object-view
Vue.js component for displaying arbitrary JavaScript values (supporting circular references)
See the live demo to try it out. (demo app on github)
About
The main purpose of this component is to display complex JavaScript values that may contain circular references. The component renders the value as a tree that can be manually expanded to display nested values.
The experience is very similar to inspecting JavaScript objects using the browser developer tools. The component was created to build the in-browser JavaScript debugger for the PARAPPLE project.
Usage
# Install the component
npm install --save vue-object-viewUse it just like any other Vue.js component. The value to display is passed as v-model or :value:
<VueObjectView v-model="object" />
<VueObjectView :value="anotherObject" />Properties
| Property | Meaning | Default |
|---|---|---|
nowrap |
Prevent word wrap (display the unexpanded value on a single line) | true |
expandButtonText |
Content of the expand button | '...' |
Styling
If you wish to change the visual appearance of the component, set the following CSS classes in your application stylesheet:
vue-object-view - Main component element
vue-object-view-primitive - Element wrapping primitive values
vue-object-view-complex - Element wrapping Objects and Arrays
vue-object-view-open - The open button (chevron left/down)
vue-object-view-expand - The expand button (...)