Skip to content

Tankōbon / lib/library-structure / setLevel

Function: setLevel() ​

setLevel(structure, index, level): LibraryLevel[]

Defined in: lib/library-structure.ts:28

structure with position index set to level; null empties that position and the ones after it. A first level changed to anything but letter/year keeps the levels after it; changed to one of them, it drops a later letter/year (which can't happen) and any duplicate.

Parameters ​

structure ​

readonly LibraryLevel[]

index ​

number

level ​

LibraryLevel | null

Returns ​

LibraryLevel[]