Skip to content

How to declare an object array #2083

@1234567845246

Description

@1234567845246

How can I declare an array of objects during initialization
export interface FoldersHistory { id?: number, paths: { address: string; isFile: boolean; }[], filesCount: number, foldersCount: number }
This is the object I defined
class Database extends Dexie { foldershistory !: Dexie.Table<FoldersHistory, number> | undefined; constructor() { super('ClipboadHistory'); this.version(1).stores({ foldershistory: "++id,paths,filesCount,foldersCount" }) } }
But in the Electron debugger, there is no data in the paths page
image
The other two pages are normal
image
I don't know if this is normal, the pahts page doesn't show data like the other two pages, or it can't be shown because the paths property is an array of objects

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions