preferences: {
    forAllColumns<P extends BasePlugin<any>, Data = unknown>(
        table: Table<Data>,
        klass: Class<P>,
    ): { delete(key: string): undefined | void };
    forColumn<P extends BasePlugin<any>, Data = unknown>(
        column: Column<Data>,
        klass: Class<P>,
    ): {
        delete(key: string): undefined | void;
        get(key: string): unknown;
        set(key: string, value: unknown): void;
    };
    forTable<P extends BasePlugin<any>, Data = unknown>(
        table: Table<Data>,
        klass: Class<P>,
    ): {
        delete(key: string): undefined | void;
        get(key: string): unknown;
        set(key: string, value: unknown): undefined | void;
    };
} = ...

Type declaration

  • forAllColumns:function
    • returns an object for bulk updating preferences data for all columns (scoped to key and table)

      Type Parameters

      Parameters

      Returns { delete(key: string): undefined | void }

      • delete:function
        • delete an entry on every column in the underlying column Map for this table-plugin pair

          Parameters

          • key: string

          Returns undefined | void

  • forColumn:function
    • returns an object for getting and setting preferences data based on the column (scoped to key)

      Only the provided plugin will have access to these preferences (though, if other plugins can guess how the underlying plugin access works, they can access this data, too. No security guaranteed)

      Type Parameters

      Parameters

      Returns {
          delete(key: string): undefined | void;
          get(key: string): unknown;
          set(key: string, value: unknown): void;
      }

      • delete:function
        • delete an entry on the underlying Map used for this column-plugin pair

          Parameters

          • key: string

          Returns undefined | void

      • get:function
      • set:function
        • set an entry on the underlying Map used for this column-plugin pair

          Parameters

          • key: string
          • value: unknown

          Returns void

  • forTable:function
    • returns an object for getting and setting preferences data based on the table (scoped to the key: "table")

      Only the provided plugin will have access to these preferences (though, if other plugins can guess how the underlying plugin access works, they can access this data, too. No security guaranteed)

      Type Parameters

      Parameters

      Returns {
          delete(key: string): undefined | void;
          get(key: string): unknown;
          set(key: string, value: unknown): undefined | void;
      }

      • delete:function
        • delete an entry on the underlying Map used for this table-plugin pair

          Parameters

          • key: string

          Returns undefined | void

      • get:function
      • set:function
        • set an entry on the underlying Map used for this table-plugin pair

          Parameters

          • key: string
          • value: unknown

          Returns undefined | void