prorm API Reference
    Preparing search index...

    Function setEncryptionAdapter

    TypeScript Decorators / Annotations for ts-prorm-orm

    Exports all decorator utilities organized by category:

    Encryption —

    /

    for password hashing Procedures —

    /

    for stored procedures & SQL functions Views —

    for mapping a Model class to a database view Permissions —

    /

    /

    /

    /

    • Set the global encryption adapter used by all

      Parameters

      Returns void

      fields that do not specify their own adapter.

      Call this once during application bootstrap, e.g.:

      import bcrypt from 'bcrypt'; setEncryptionAdapter({ hash: (v) => bcrypt.hash(v, 12), verify: (plain, hash) => bcrypt.compare(plain, hash), });