Back to Pocketbase

Interface MigrationsList

static/jsvm/interfaces/core.MigrationsList.html

latest2.2 KB
Original Source

Interface MigrationsList

MigrationsList defines a list with migration definitions

Hierarchy

  • MigrationsList

Index

Methods

addcopyitemitemsregister

Methods

add

  • add(m): void

Add adds adds an existing migration definition to the list.

If m.File is not provided, it will try to get the name from its .go file.

The list will be sorted automatically based on the migrations file name.

Parameters

m: Migration

Returns void

copy

  • copy(list): void

Copy copies all provided list migrations into the current one.

Parameters

list: MigrationsList

Returns void

item

Item returns a single migration from the list by its index.

Parameters

index: number

Returns Migration

items

Items returns the internal migrations list slice.

Returns Migration[]

register

  • register(up, down, ...optFilename): void

Register adds new migration definition to the list.

If optFilename is not provided, it will try to get the name from its .go file.

The list will be sorted automatically based on the migrations file name.

Parameters

up: ((txApp) => void)
- 
  - (txApp): void
  - 

Parameters

    - 
txApp: App

Returns void

down: ((txApp) => void)
- 
  - (txApp): void
  - 

Parameters

    - 
txApp: App

Returns void

Rest ...optFilename: string[]

Returns void

Settings

Member Visibility

  • Inherited

Theme

OSLightDark

On This Page

Generated using TypeDoc