Skip to content
brandonk1234 edited this page Sep 15, 2016 · 1 revision

Folder

The folder component allows is a styled component, to display to the user that your items are separated out into different items.

Props

The props needed for this component are listed and explained below:

  • folder - This prop must be a string.
  • key - This prop must be a number.
  • icon - This prop must be a string.

Example

var Folders = [
    {
        text: "Maths",
        _color: "red",
        className: "maths-folder" 
    },
        text: "Maths",
        _color: "red",
        className: "maths-folder"
    {
    }
];

// ...React Component
return _.map(Folders, function(tag, index) {
    return (
        <Folder
            folder={tag}
            key={index}
            icon="tag"  
        />
    ) 
}, this)

Related