diff --git a/.storybook/jsx.stories.js b/.storybook/jsx.stories.js index 71457510..e99b0b06 100644 --- a/.storybook/jsx.stories.js +++ b/.storybook/jsx.stories.js @@ -35,6 +35,10 @@ const Button = jsx('button', { } }); +const ButtonYellow = jsx(Button, { + color: 'yellow' +}); + storiesOf('jsx()', module) .add('Default', () => h(RedBorder, null, 'Hello world') @@ -50,3 +54,8 @@ storiesOf('jsx()', module) h(Button, null, 'Click me!') ) ) + .add('Composition', () => + h(Block, null, + h(ButtonYellow, null, 'Click me!') + ) + ) diff --git a/addon/extend.js b/addon/extend.js deleted file mode 100644 index e69de29b..00000000 diff --git a/addon/jsx.js b/addon/jsx.js index 22d395b6..57dc2b29 100644 --- a/addon/jsx.js +++ b/addon/jsx.js @@ -15,9 +15,6 @@ exports.addon = function (renderer) { var className; var isElement = typeof fn === 'string'; - if (!block && !isElement) - block = fn.displayName || fn.name; - var Component = function (props) { if (!className) { className = renderer.rule(styles, block);