diff --git a/styleguidist/styleguide.config.js b/styleguidist/styleguide.config.js index 3a7c52b..bef947a 100644 --- a/styleguidist/styleguide.config.js +++ b/styleguidist/styleguide.config.js @@ -109,4 +109,16 @@ module.exports = { * @default false */ defaultExample: false, + + /** + * Returns the value of the import statement below a components name. + * @function + * @example import ItemTable from ./component/ItemTable/ + * @override + */ + getComponentPathLine(componentPath) { + const name = path.basename(componentPath, '.js') + const dir = path.dirname(componentPath) + return `import ${name} from '${dir}/';` + } } \ No newline at end of file