SyntaxFix
Write A Post
Hire A Developer
Questions
You simply misspelled $stateParam, it should be $stateParams (with an s). That's why you get undefined ;)
$stateParam
$stateParams