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

Pass arguments from accept() to next steps #466

Closed
Tracked by #396
cocopon opened this issue Jan 28, 2023 · 1 comment
Closed
Tracked by #396

Pass arguments from accept() to next steps #466

cocopon opened this issue Jan 28, 2023 · 1 comment
Milestone

Comments

@cocopon
Copy link
Owner

cocopon commented Jan 28, 2023

Currently there is no way to pass parsed arguments from accept() to next steps (binding() or controller()). This causes unnecessary duplicate parsing.

Example:

const format = detectStringColorFormat(value, extractColorType(params));
if (!format) {
return null;
}

if (!format) {
throw TpError.shouldNeverHappen();
}

@cocopon cocopon added this to the 4.0.0 milestone Jan 28, 2023
@cocopon cocopon mentioned this issue Jan 28, 2023
24 tasks
cocopon added a commit that referenced this issue Feb 3, 2023
@cocopon
Copy link
Owner Author

cocopon commented Feb 3, 2023

It can also be implemented on the current structure like this:

params: {
...result,
supportsAlpha: shouldSupportAlpha(params),
},

@cocopon cocopon closed this as completed Feb 3, 2023
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

1 participant