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

Ship with spec validation interceptor #515

Closed
ghost opened this issue Nov 22, 2018 · 4 comments
Closed

Ship with spec validation interceptor #515

ghost opened this issue Nov 22, 2018 · 4 comments

Comments

@ghost
Copy link

ghost commented Nov 22, 2018

It would be nice if re-frame could bring a few more batteries, like a spec validation interceptor for the application state (i.e. :db). It could explain validation errors on the browser JavaScript console, roll back the offending changes, integrate with re-frame-10x, ...

kee-frame comes with such an interceptor, but it's focus is on other unrelated, new concepts (controllers).

Something similar was requested in #457, but the main focus of that ticket lies elsewhere.

@danielcompton
Copy link
Contributor

danielcompton commented Nov 22, 2018

Spec is still in alpha, I don't think anyone outside of Cognitect has a good idea of where it's going to end up. I'm pretty hesitant to put anything core to spec in re-frame at the moment. I'm a little bit worried about the upgrade path, and how we might have to support multiple versions in re-frame, error message formatting, and perhaps picking the wrong abstractions.

re-frame is very flexible, so you can add these kinds of things yourself. If you make one we'd be happy to add it to the re-frame resources.

@mike-thompson-day8
Copy link
Contributor

@urzds as @danielcompton says we look forward to officially integrating spec when it becomes stable but without a known timeline for that, I'm going to close this issue for now.

@ghost
Copy link
Author

ghost commented Nov 23, 2018

What about Plumatic Schema as an alternative?

@mike-thompson-day8
Copy link
Contributor

@urzds

What about Plumatic Schema as an alternative?

spec is the way of the future so we'll embrace that officially in due course. And, in the time being, you can easily engineer to use either spec or Schema yourself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants