Acces query params in view


#1

Hi, I want to change the class of a div in base of a params in the url, is possible to access to the query params value in the view??

For example

{{#if queryParams.ctx == ecc??? Where ctx is my param


#2

You should be defining query params in your controller, once that’s done it’s easy to use them in your view.

https://guides.emberjs.com/v2.6.0/routing/query-params/


#3

ok thanks for the help