Variable: EMPTY_ARR
const
EMPTY_ARR: readonlynever
[]
An empty array that is frozen in development mode for immutability. Use this constant instead of creating new empty arrays to improve performance.
Example
typescript
// Good
const items = someCondition ? userItems : EMPTY_ARR
// Instead of
const items = someCondition ? userItems : []