Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/angular/angular
/ last
Function
last
packages/language-service/testing/src/util.ts:164–169 ·
view source on GitHub ↗
(array: T[])
Source
from the content-addressed store, hash-verified
162
}
163
164
function
last<T>(array: T[]): T {
165
if
(array.length === 0) {
166
throw
new
Error(`last() called on empty array`);
167
}
168
return
array[array.length - 1];
169
}
Callers
1
assertFileNames
Function · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected