arktype icon indicating copy to clipboard operation
arktype copied to clipboard

Add `objectPath` to validation context

Open Dimava opened this issue 10 months ago • 1 comments

Request a feature

Add objectPath (along with existing root and path) to validation context

🤷 Motivation

During validation, you may want to get current parentNode, parentNode.parentNode and so on Make an array with them for easy accedd

💡 Solution

Context may have readonly list of currently visited nodes, top to bottom, like in DFS graph algos, with the first being root node , and the last being parent node

Dimava avatar Aug 18 '23 21:08 Dimava