I'm Andrew. I work @ Shopify as a web developer.
I like working with JavaScript, TypeScript, and React.
Say hi over on twitter!
A VS Code extension for generating new react component files
Home Page: https://marketplace.visualstudio.com/items?itemName=AndrewMcGoveran.react-component-generator
License: MIT License
className={styles.ComponentName}
to the rendered div
.ComponentName
ruleComponentNameProps
export * β¦.
in the ComponentName/index.ts
fileapp/components/index.ts
I like to organize my components by type.
For example:
-components
-dialogs
-dialogcomponent1
-dialogcomponent2
-lists
-todoList
-shoppingList
etc..
If right clicking the dialogs folder and selecting to Generate a new react component it will add a components folder under the dialogs.
I would like to have a setting to avoid this.
When generating a stories file, we are presented with errors on the import statment:
'@storybook/react/types-6-0' import is restricted from being used. Import types from
@storybook/react
instead
Switching to import as suggested presents this error:
NOTE that in Storybook 7.0, this type will be renamed to StoryFn and replaced by the current StoryObj type.
'Story' import from '@storybook/react' is restricted. Avoid using
Story
andComponentStory
. UseStoryFn
/ComponentStoryFn
for function stories (CSF v2), orStoryObj
/ComponentStoryObj
for object stories (CSF v3). See https://storybook.js.org/blog/component-story-format-3-0/ and https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#storyobj-type
I'd like to have option to disable the creation of 'test' folder, and put the test file outside per our repo's style. Also if there is an option to decide whether the name is *.test.tsx or *.spec.tsx would be great
When right clicking a directory and selecting "Generate Storybook stories file", it'd be nice if the component name was pre-populated in the prompt field, or even better if there weren't even any prompts and the file was directly created.
Suggested in #27
When generating a JS component, an invalid interface is included:
Pointed out in #27
This is no longer needed in most cases thanks to the new JSX transform:
https://reactjs.org/blog/2020/09/22/introducing-the-new-jsx-transform.html
Hi! I wonder if there is any plan to update the storybook template to adopt CSF3?
When people land on this repo, it'd be great if they had a way to quickly install the Extension.
I suggest setting https://marketplace.visualstudio.com/items?itemName=AndrewMcGoveran.react-component-generator
as the URL for this repo.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.