How to add a new component?

Create an new js file in 'js/components/list' directory

Add it's name without .js extension in the 'js/components/define.js' file array in order to be listed

In your new file start building the component using the boilerplate code


    title: '',
    form: {
        align: true,
        inputList: [
                type: 'text',
                tooltip: 'Give a title to the new component',
                label: 'Dummy text',
                dataName: 'title'
    template: [
        '<p <%= align %>><%= title %></p>'

Here is the list of avaible options

  • title: type[string], name that well be used in components sidebar list
  • form: type[object], components style options and fields to complete
    • align: type[boolean], add align select field, return a class used for aligning content
    • borderRadius: type[boolean], add border-radius options field, return border-radius value in px
    • border: type[boolean], add border top and bottom options field, return
    • columns: type[boolean],

Last update:
2014-11-18 14:23
Cristina Cavruc
Average rating: 5 (1 Vote)