generate:component script improvements
I ran across a few places where we could improve the generate component plop script, so I am capturing them here.
Storybook Template ➡ !1543 (merged)
Include scaffolding for props and data additions.
Import Paths ➡ !1551 (merged)
A number of path resolution issues needed to be fixed manually after generating a component.
See details.
In src/scss/components.scss:
@import '../componentssrc/components/base/combobox/combobox';
should be
@import '../components/base/combobox/combobox';
In /documentation/components_documentation.js
export { default as GlComboboxDocumentation } from '../src/componentssrc/components/base/combobox/combobox.documentation';
should be
export { default as GlComboboxDocumentation } from '../src/components/base/combobox/combobox.documentation';
In index.js
export { default as GlCombobox } from './src/componentssrc/components/base/combobox/combobox.vue';
should be
export { default as GlCombobox } from './src/components/base/combobox/combobox.vue';
In *.stories.js
'../../../../../documentation/documented_stories'
should be
'../../../../documentation/documented_stories'
Documentation Notes in componentName.md ➡ !1554 (merged)
Replace https://design.gitlab.com/components/ with https://design.gitlab.com/components/status, since the original link returns a 403.
Edited by Sarah Groff Hennigh-Palermo