After researching online, I came across the following format:
twoDArr: string[][] = [['a', 'b', 'c'], ['x', 'x']]
However, upon trying to console.log(twoDArr)
, I encountered a TypeScript error indicating
Parameter 'twoDArr' implicitly has an 'any' type.
What could be causing this issue?
It's worth mentioning that I am adamant about maintaining my typing and not resorting to using any.