I have two variables and need to insert string b into string a at the point after href.
var a = '<a href="http://pix6.agoda.net/">Image Credit</a>';
var b = 'rel="nofollow noreferrer noopener"';
The result I'm looking for is
<a href="http://pix6.agoda.net/" rel="nofollow noreferrer noopener">Image Credit</a>
How can I do this with JavaScript?