Yasir, 30, finished with 10-141 as Pakistan beat England by 75 runs in the first Test at Lord's last week.
Stokes and James Anderson missed the match but both return for Friday's second Test at Old Trafford.
"They're a very good team but we go into the Test knowing how he goes about bowling and we should be able to counteract that," Stokes said.
Yasir, who has taken 86 wickets in 13 Tests, has moved to the top of the Test bowling rankings, the first leg-spinner to do so since Warne 11 years ago.
Australian Warne, who retired from Test cricket in 2007, is second only to Muttiah Muralitharan in the all-time list of Test wicket-takers, with 708 from 145 matches at an average of 25.41.
Stokes, 25, has been missing for England after jarring his knee in the first Test of the summer against Sri Lanka in May, an injury which required surgery.
Having played solely as a batsman for his county Durham in the early stages of his comeback, he bowled in the victory over Lancashire at Southport last week, taking 3-50 from 19 overs in the second innings.
"I have been bowling in the nets but you can't replicate doing that, the only thing you can do is bowl in a game," he said. "So it was good on that point and it was a massive confidence boost."