Skip to content

serialize is not a function #1989

Open
Open
@matf5

Description

What version of Ajv are you using? Does the issue happen if you use the latest version?
6.12.5

Ajv options object

      meta: {
        $schema: 'http://json-schema.org/draft-07/schema#',
      },
      $data: true,
      allErrors: true,
      jsonPointers: true,
    }

JSON Schema

Sample data

Your code

    const defaultOptions = {
      meta: {
        $schema: 'http://json-schema.org/draft-07/schema#',
      },
      $data: true,
      allErrors: true,
      jsonPointers: true,
    };
    const ajv = new Ajv({
      ...defaultOptions,
    });

Validation result, data AFTER validation, error messages


What results did you expect?

expect to init an ajv object

Are you going to resolve the issue?
throw error "serialize is not a function"
I set a debug point, it seems to be a string, not a function
image

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions