How can I capture the default product variant ID with JavaScript?

How can I capture the default product variant ID with JavaScript?

pramodraam
Shopify Partner
77 2 9

Could you please help with one liner JS code to get the default variant ID of the product? I want to capture the variant id when this page loads. 

https://www.fabretro.com/products/engraved-20oz-pilsner-tumbler-i?_pos=1&_psq=test&_ss=e&_v=1.0&vari...

Regards,

Pramod

Replies 0 (0)