Skip to content

Component Folder Structure

Jaison Justus edited this page Sep 18, 2015 · 1 revision

Consider scaffolding a component, for example a Button. Once you scaffold you get a folder named /Button inside the component target folder you specified in the reactive configuration file eg: src/components/Button/

/Button
	├── component.json
	├── src
	│   ├── Button.scss
	│   ├── index.jade
	│   └── jsx
	│       ├── Button.jsx
	│       └── trigger.jsx
	└── test
   		└── Button.jsx

####Component.json This is packageing file for the components. This file is just like a bower.json or package.json file.

{
  "name" : "Button",
  "author" : "jaison.justus.lp@gmail.com",
  "keywords" : ["button", "success", "ok", "cancel", "danger", "primary"],
  "description" : "Simple button component with three presentation state Primary, Success and Danger",
  "dependencies" : {
    "s-css": [],
    "js-x": [],
    "components" : []
  }
}

Clone this wiki locally