How to use @storybook/addon-docs/blocks <Props /> for Vue components in regular Stories?

Viewed 338

We can extract the Vue component's Props into docs by writing this code in MDX

import { Props } from "@storybook/addon-docs/blocks";
import MyComponent from "./index.vue";

<Props of={MyComponent} />;

How can I achieve the same thing in regular stories?

import MyComponent from "./index.vue";
import { Props } from "@storybook/addon-docs/blocks";
// I don't know where to put `Props`

export default {
  title: "MyComponent",
};

export const MyComponentStory = () => ({
  components: { MyComponent },
  template: `
    <MyComponent />
  `,
});

What should I do to achieve the same thing?

0 Answers
Related