squarespacejsontemplate

squarespace multiple index page styles


The Squarespace docs say

Each template family has its own Index style that falls into one of three designs: Grid, Stacked, Slideshow.

In index.conf, I see I can change the indexType, and I suppose I can also change the layout to represent a grid. But I'm using the stacked layout as well.

Is there any way to define two template styles to use on different index pages?

{
  "title" : "Index",
  "newTitle": "New Index",
  "folder": true,
  "fullData": true,
  "acceptTypes" : [ "page", "gallery" ],
  "addText": "Add Section",
  "icon": "stacked",
  "index" : true,
  "indexType": "stacked"
}

Solution

  • Yes, you can accomplish that by defining two index collection types, each with its own .conf, .list, and/or .item files. You can leave one as the default index.* and then create a custom collection by copy/pasting those same files and naming them indexgrid.*. Then, update the necessary values (title, icon and indexType) in the indexgrid.conf file.

    Of course, you'd probably copy an actual grid-based .list file from a template with a grid-based index page. That way you wouldn't have to write your own HTML for the grid index.

    Having done that, and having uploaded your changes (and refreshing your Squarespace editing window), you'll then be able to select between "Index" and "Index-Grid" (or whatever you typed as your 'title' attribute) when creating a new page.

    You could of course rename the index.* files to indexstacked.* and then set the title attribute to "Index-Stacked" if you wanted. That way you wouldn't have to remember that the plain "Index" page type is "stacked".