ajv-validator / ajv-validator/ajv-keywords

Allow adding custom transform filters

Open
#99 0 comments 9 reactions 0 assignees View on GitHub
enhancement
Dominant language
TypeScript
Stars
257
Forks
51
PR merge metrics
No merged PRs in 30d

Description

`dynamicDefaults` allow users to add their own defaults functions by exporting `DEFAULTS` in the keyword, as so: https://github.com/epoberezkin/ajv-keywords/blob/master/keywords/dynamicDefaults.js#L49

However, `transform` does not export the transform variable - https://github.com/epoberezkin/ajv-keywords/blob/master/keywords/transform.js#L4 - and so there's literally no way for users to add custom transformations.

I think you should export the `transform` variable like you do in `dynamicDefaults` and allow people to add their own transformations, rather than bolting in other transformations like in #95 or #66.

Thanks!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.