Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Addon-docs: Extract ArgType parameters by component #10844

Closed
shilman opened this issue May 20, 2020 · 4 comments
Closed

Addon-docs: Extract ArgType parameters by component #10844

shilman opened this issue May 20, 2020 · 4 comments

Comments

@shilman
Copy link
Member

shilman commented May 20, 2020

#10373 intended to reduce the data sent over the channel on app startup by "normalizing" story parameters (e.g. sending component-level parameters once per component rather than once per story).

It appears that component ArgTypes are being sent per-story rather than per-component, thus losing out on a performance opportunity. Need to fix the argTypes extractor to do the right thing.

@shilman shilman added this to the 6.0 args milestone May 20, 2020
@shilman shilman self-assigned this May 20, 2020
@shilman shilman changed the title Addon-docs: ArgType parameters by component Addon-docs: Define ArgType parameters by component May 28, 2020
@shilman shilman changed the title Addon-docs: Define ArgType parameters by component Addon-docs: Extract ArgType parameters by component May 28, 2020
@shilman
Copy link
Member Author

shilman commented Jun 7, 2020

@tmeasday this requires:

  • a protocol for enhancers to know whether they are being called on component/kind parameters or story parameters
  • enhancers to be updated to support this protocol
  • story store to be updated to support the protocol and to call the enhancers on kind parameters

Pretty sure I'd come up with a plan when we did the normalization work, but none of that is implemented AFAICT and it seems like a bigger task than I'd thought. WDYT?

@tmeasday
Copy link
Member

tmeasday commented Jun 8, 2020

Sounds about right! I'm not sure how hard it is to update the individual enhancers @shilman but if we decide on the API the store part will be quick I think.

@matheo
Copy link
Member

matheo commented Jun 8, 2020

@tmeasday I've highlighted all the extractors in this PR: https://github.com/storybookjs/storybook/pull/11068/files

In the code, I only see one enhanceArgTypes in docs/frameworks/common
and I'm assuming that's the one to be called once by component @shilman?

@tmeasday tmeasday self-assigned this Jun 9, 2020
@tmeasday tmeasday removed their assignment Jun 10, 2020
@stale stale bot added the inactive label Jul 3, 2020
@storybookjs storybookjs deleted a comment from stale bot Jul 3, 2020
@stale stale bot removed the inactive label Jul 3, 2020
@shilman shilman modified the milestones: 6.0 args, 6.1 perf Jul 4, 2020
@shilman shilman modified the milestones: 6.1 perf, 6.0 Jul 29, 2020
@shilman shilman removed the tracked label Jul 31, 2020
@shilman shilman removed this from the 6.1 perf milestone Oct 13, 2020
@shilman shilman added this to the 6.2 perf milestone Oct 13, 2020
@shilman
Copy link
Member Author

shilman commented May 20, 2022

Won't fix. On-demand architecture fixes plus we're moving to annotations server in the future.

@shilman shilman closed this as completed May 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants