Experimenting with SharePoint Hub Sites

A colleague (@spbrusso) and I have been playing with hub sites for the last few days.  We noticed some quirky things and started digging around and this is what we found.

Navigation

When you create a hub site, a directory is created under _Catalogs and it’s appropriately called “hubsite”.

hubsite catalog

In that folder is a json file containing your new nav bar details which include the logo and urls.  This nav bar doesn’t appear to automatically pick up joined sites.  You must manually manage your navigation from the hub site.

hub site nav

Here is a sample of that json file.


{

  "themeKey": null,

  "name": "Hub Site",

  "url": "https://.sharepoint.com/sites/HubSite2",

  "logoUrl": null,

  "usesMetadataNavigation": false,

  "navigation": [

    {

      "Id": 2003,

      "Title": "Team Two",

      "Url": "https://.sharepoint.com/sites/teamtwo",

      "IsDocLib": false,

      "IsExternal": false,

      "ParentId": 1002,

      "ListTemplateType": 0,

      "Children": [ ]

    }

  ]

}

Associated Sites

The top navigation doesn’t propagate immediately and isn’t controlled by the normal Navigation settings that we’ve used in the past.  My guess is that there is a timer job running in the background that updates the top navigation for associated sites.  When it runs, the json file at the hub is copied to the same location at the associated site.  If you change the navigation at the hub, know that you may need to wait an hour or so for the associated sites to show the same top nav.  (I didn’t time it, but I believe I waited 45-60 minutes before I saw a change).  You can’t edit the top nav from the associated site; you have to do it from the hub.

If you crack open the hub site with the SharePoint Client Browser tool, you’ll see the navigation node with the links that you’ve created.  This is not the case on the associated sites so I’m thinking that the process is that a user creates the nav, which is stored in that Top Nav Bar, the items get copied to the file, the file gets copied to the associated sites, and the associated sites read from their copies.

hub site top nav

Theme

When you first create a modern team site, not associated with a hub site yet, you will see a random theme applied.  If you leave the default theme on the hub site and then associate sites to it, they appear to keep their own theme.

If you set a theme at the hub and then associate a site to it, that site will instantly pick up the theme.

If you change the hub site’s theme, the associated sites won’t pick up the change until you disassociate them from the hub and re-associate.  I tried changing the top navigation and waiting to see if the theme would change when the nav changes were propagated but they didn’t.

Update: If you change the hub site’s theme, the associated sites may take 2 or more hours to pick up the theme change.  

 

 

 

 

Unable to Delete Some Sites in the Admin Center’s New Site Management Page

I noticed a little quirk in the new Site Management page.  It’s new so I don’t expect it to be perfect.  I was playing with Hub Sites for a separate blog post and I wanted to start from scratch so I deleted my Hub Site via the UI.  I then tried to delete the site that was joined to the hub but I wasn’t given the option to.  The issue wasn’t limited to sites that were associated with hub sites either.

Here’s a communication site that I am able to delete.  It also happens to be a hub site but the issue isn’t specific to hub sites or communication sites.

Site Management with delete

And here’s the site that I wanted to delete.  You’ll notice that the Delete icon is missing.  A few other sites were like that too.

Site Management without delete

I had to resort to PowerShell to remove the site.

Remove-SPOSite https://tenant.sharepoint/sites/teamone