From 182e74b4b3190eefeed2b8932059f2e1216ae196 Mon Sep 17 00:00:00 2001 From: Hoa Nguyen Thai Date: Tue, 5 Mar 2019 12:04:36 +0700 Subject: [PATCH] add rax support for centered --- addons/centered/rax.js | 1 + addons/centered/src/rax.js | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 addons/centered/rax.js create mode 100644 addons/centered/src/rax.js diff --git a/addons/centered/rax.js b/addons/centered/rax.js new file mode 100644 index 00000000000..232893d57a2 --- /dev/null +++ b/addons/centered/rax.js @@ -0,0 +1 @@ +module.exports = require('./dist/rax'); diff --git a/addons/centered/src/rax.js b/addons/centered/src/rax.js new file mode 100644 index 00000000000..cff9fa35876 --- /dev/null +++ b/addons/centered/src/rax.js @@ -0,0 +1,18 @@ +/** @jsx createElement */ +// eslint-disable-next-line import/no-extraneous-dependencies +import { createElement } from 'rax'; +// eslint-disable-next-line import/no-extraneous-dependencies +import View from 'rax-view'; +import styles from './styles'; + +export default function(storyFn) { + return ( + + {storyFn()} + + ); +} + +if (module && module.hot && module.hot.decline) { + module.hot.decline(); +}