I set up a structure on my product page where I can update the URL with js after the users select the variant of the product.
Below is a basic code example.
{% for variant in product.variants %}
{% assign vTitle = variant.title | split: " / " %}
{% endfor %}
The URL,
normally …/products/shirt,
is rendered as …/products/shirt?variant=black&id=111111111111
after the user’s variant selections.
When I search the newly created URL in Google search console, Google does not index this URL.
Finally; I think the reason is because it is the URL created by the interaction of the user. But I need to create these URLs somehow.
I need your support on this matter.