@redningsselskapet/class-validator-ais
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.3 • Public • Published

    Description

    Custom class-validator for automatic identification system (ais)

    usage:

    class AisdataDto {
      @IsMmsi()
      mmsi: string
     
      @IsCog()
      heading: number
     
      @IsSog()
      speed: number,
    }
     
    // validate Object
    const creatAisdataDto = new AisdataDto();
    const error = await validate(createAisdataDto);
    if (error.length > 0) {
      console.log(error)
    }

    Install

    npm i @redningsselskapet/class-validator-ais

    DownloadsWeekly Downloads

    113

    Version

    1.0.3

    License

    ISC

    Unpacked Size

    6.39 kB

    Total Files

    4

    Last publish

    Collaborators

    • avatar