But why does it exist?
It depends on what you mean
The reason Metapsi exists now is very different from the reason it was initially created.
Core idea
Metapsi appeared as an experiment based on the question:
Can we represent application behaviour with a configurable, formal set of business rules?
The examples that would always pop-up where hiding client-side controls based on the value of other controls, making controls mandatory, dynamically resizing controls, etc. We were aware of some approaches to tackle this, like decision tables, or simply picking a fixed set of scenarios and creating custom configurations for them. Yet, when attempting to actually apply solutions in real-world scenarios, some corner-case would always break something. Things always seemed to veer towards more complexity, which turned out to somehow require the solution to be Turing-complete. We finally figured we asked the wrong question.
A less abstract world
All applications behave according to a formal set of business rules: the application code! What we actually wanted is to keep two execution environments synchronized, the server and the client side. In a concrete, application development world, the question got rephrased to:
Can we express JavaScript behaviour in C#?
Apparently a much lower-level scope. Yet, the implications turned out to be quite huge. You'd figure we would notice. Well, it took us a couple of years...
Client-side behaviour in Nuget packages
Fundamentally, the inovation Metapsi is based on is nothing more than a lightweight, lean C# library that outputs JavaScript. String concatenation on steroids, if you will. It is actually the way it is employed that makes all the difference. And it is especially useful when you don't see it: the critical result is that client-side code is no different from the rest of your application code in any sort of way. It does not need a separate development environment, a separate deployment step, separate versioning, etc. Everything just ... works.
Metapsi
Build with confidence
Metapsi projects
Q Web Solutions
©2025 Q WEB SOLUTIONS