Most places have laws requiring recognition of unions past certain sizes or following votes, even if they don't require membership of the union.
The main distinction is not whether membership of a union is required - closed shops is illegal both in the US (since the Taft-Hartley Act 1947) and in all countries bound by the European Court of Human Rights (which is basically every country eligible for Council of Europe membership apart from Belarus, Kazakhstan and the Vatican) - but whether or not non-members are required to pay dues towards a recognised union.
The main distinction is not whether membership of a union is required - closed shops is illegal both in the US (since the Taft-Hartley Act 1947) and in all countries bound by the European Court of Human Rights (which is basically every country eligible for Council of Europe membership apart from Belarus, Kazakhstan and the Vatican) - but whether or not non-members are required to pay dues towards a recognised union.