2 ms·
Well… I asked the (admittedly poorly phrased) question: "With deno and oak, how can I validate the input and cast it in the different routes?" Phind suggested
by baumschubser 3y ago
Well… I asked the (admittedly poorly phrased) question: "With deno and oak, how can I validate the input and cast it in the different routes?"
Phind suggested "one way is to use the built-in validation middleware provided by Oak, called validator.". It went on to describe this middleware, its helper functions and give me code examples how to use it.
Thing is: This "validator" middleware does not exist.
I asked for more examples, and Phind provided me with more examples, listing all validation functions.
When I said that there is no such thing as a built-in validator middleware in Oak, Phing admitted that it appears to be removed in version 6.0 (we are currently at version 11), according to the Oak documentation (with a link to it's Github repo - where I did not find any match in code for "validator").
- rushingcreek 3y agoSeemed to work for me on Expert mode: https://www.phind.com/search?cache=9fcb1774-f299-435f-a6cc-4b7f999f6de7 https://www.phind.com/search?cache=9fcb1774-f299-435f-a6cc-4.... I highly recommend using Expert mode over the default mode for these types of searches.