Refactor custom types API.
Drop `validate` and `resolve` loader options.