The Scottish National Party was formed in 1934 from the merging of two existing parties -the National Party of Scotland and the Scottish Party.
The NPS had been established in 1928 after the failure of successive Home Rule Bills had led to campaigners becoming disillusioned with all the established mainstream parties -and particularly with Labour.
The Scottish Party (styled the "Moderates") were conceived of in 1932 as an alternative nationalist party for those who saw the NPS as too separatist and left wing.
Despite those differences the two did come together successfully. After all, most political parties are "broad churches" anyway. And, in any case, for the first 14 years it was possible to be a member of both the SNP and another party.
In 1943 however dual membership was banned for office holders. In 1948 this ban was extended to the whole party.
However the Party still retained its key distinguishing features -its decentralist structure and ites emphasis on grassroots participation/activism. It was still almost entirely a voluntary party. Its' leaders often had full time employment outside of politics. What's more those leaders were actually referred to as the "Chairman" or "Convenor" and were kept in check by the Annual Conference, the key decision making body of the party.
Further Reading: Mitchell, Bennie and Johns, THE SNP:Transition to Power (2012).