You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However just realized perhaps is-my-schema-valid cannot compare RegExp objects as they are not by default in JSON.stringify(). @mafintosh, how difficult to extend the plugin, perhaps similar like replacer and reviver functions to faciltate comparisons of objects?
Taking a hint from how webpack lets you choose loaders based on regexing (somewhat implicit understood) filetypes, could apply arrows of validators to specific files, or subtrees of resolved output objects.
Would be super simple, essentially wrap a module into
(x, f) => f(x)wheref(x)istrueorf(x)isfalse.xcan then be something likeHowever just realized perhaps is-my-schema-valid cannot compare
RegExpobjects as they are not by default inJSON.stringify(). @mafintosh, how difficult to extend the plugin, perhaps similar likereplacerandreviverfunctions to faciltate comparisons of objects?Taking a hint from how webpack lets you choose loaders based on regexing (somewhat implicit understood) filetypes, could apply arrows of validators to specific files, or subtrees of resolved output objects.