Jump to content

Import custom code from file repository to product page

Recommended Posts

Site URL: https://wolverine-sparrow-dk96.squarespace.com/

I currently have a lot of custom code written locally on my computer for my product pages on my website, which I insert under the additional product information section on each product. This works okay but is very time consuming to copy and paste to all products when I make a universal change to all the products.

What I would like to do is to import this code directly to the product pages.

Using Github I've committed all of these custom files to my repository, into the assets folder.

My question is, how can I import these files to their respective product pages from the repository?

Link to comment
On 11/3/2021 at 9:42 PM, deadlyserious said:

Site URL: https://wolverine-sparrow-dk96.squarespace.com/

I currently have a lot of custom code written locally on my computer for my product pages on my website, which I insert under the additional product information section on each product. This works okay but is very time consuming to copy and paste to all products when I make a universal change to all the products.

What I would like to do is to import this code directly to the product pages.

Using Github I've committed all of these custom files to my repository, into the assets folder.

My question is, how can I import these files to their respective product pages from the repository?

You can use something like a mapping using the name of the product and import the files accordingly

Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.
Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Keyword Highlighter
If you find my answer fit your need, let's leave a like or upvote so others with the same issue can find their solution. Thank you

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.