Forum Discussion

mwilliams71's avatar
mwilliams71
Brass Contributor
Sep 20, 2022

Hiding Created By: header in a SharePoint Group view

I have created a view that's grouped and it's showing the Created By: header on every item. I want to hide this with jQuery or CSS. Please help.

8 Replies

  • mwilliams71 You can use this JSON: 

     

    {
      "$schema": "https://developer.microsoft.com/json-schemas/sp/v2/row-formatting.schema.json",
      "groupProps": {
        "headerFormatter": {
          "elmType": "div",
          "style": {
            "padding-left": "12px",
            "font-size": "16px",
            "font-weight": "400",
            "cursor": "pointer",
            "outline": "0px",
            "white-space": "nowrap",
            "text-overflow": "ellipsis"
          },
          "children": [
            {
              "elmType": "div",
              "children": [
                {
                  "elmType": "span",
                  "style": {
                    "padding": "5px 5px 5px 5px"
                  },
                  "txtContent": "@group.fieldData.title"
                }
              ]
            },
            {
              "elmType": "div",
              "children": [
                {
                  "elmType": "div",
                  "style": {
                    "display": "flex",
                    "flex-direction": "row",
                    "justify-content": "center"
                  },
                  "children": [
                    {
                      "elmType": "div",
                      "txtContent": "=' (' + @group.count + ')'"
                    }
                  ]
                }
              ]
            }
          ]
        }
      }
    }

     

    Output: 

    Documentationview-formatting 


    Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

    • mwilliams71's avatar
      mwilliams71
      Brass Contributor
      How would I know if I have the modern experience version?
      • ganeshsanap's avatar
        ganeshsanap
        MVP

        mwilliams71 Go to your SharePoint list/library and check if you can see below options: 

        If you are able to see these options, follow Microsoft documentation given here to add above JSON in view formatting option: Get started with view formatting 


        Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

  • mwilliams71 If you are using SharePoint modern experience, you can remove it using JSON formatting.

     

    Check the sample I created for same at: Remove column name from group header 


    Please click Mark as Best Response & Like if my post helped you to solve your issue. This will help others to find the correct solution easily. It also closes the item. If the post was useful in other ways, please consider giving it Like.

Resources