Skip to content

Instantly share code, notes, and snippets.

@seanwash
Created June 30, 2023 17:37
Show Gist options
  • Save seanwash/000203d88fd053238c243e0955943550 to your computer and use it in GitHub Desktop.
Save seanwash/000203d88fd053238c243e0955943550 to your computer and use it in GitHub Desktop.
Klaviyo Catalog Feed Test
[{"id":1000000,"title":"Aberdine 2'2\" X 3' Rug, Aqua","description":" The simplistic yet compelling rugs from the Aberdine Collection effortlessly serve as the exemplar representation of modern decor. The meticulously woven construction of these pieces boasts durability and will provide natural charm into your decor space. Made with Polypropylene in Turkey, and has Medium Pile. Spot Clean Only, One Year Limited Warranty.\n\n <p>This part of the description isn't the description that came with the product. This is a way to to <i>rich text rendering<\/i> locally to <em>ensure<\/em> that we only support a <strong>select number<\/strong> of tags.<\/p>\n\n <br \/>\n\n We also need wrap each line in a <b>paragraph tag<\/b> to keep the styling consistent.\n\n <p>Here are some of that tags we intend to support:<\/p>\n <ul>\n <li>strong<\/li>\n <li>b<\/li>\n <li>em<\/li>\n <li>i<\/li>\n <li>br<\/li>\n <li>ul<\/li>\n <li>ol<\/li>\n <li>li<\/li>\n <\/ul>\n\n Anything outside from these will be stripped from the server side to prevent potential XSS attacks. Here are the critical ones we need to look out for:\n <ol>\n <li>script<\/li>\n <li>a<\/li>\n <\/ol>\n\n <p>Finally, would it make sense to strip all the attributes in each tags? Is that even in the realm of possibility?<\/p>\n <p>An example on why we should even consider that is if a tag that has onclick=\"() => window.location...\". This test data will have it at the call to action below.<\/p>\n\n <strong style=\"background-color: red; padding: 1rem; border-radius: 0.25rem;\" onclick=\"alert('GOTCHA!')\">CLICK ME<\/strong>","link":"https:\/\/app.onsidedoor.test\/s\/1000\/collections\/20002-rugs-mugs-accoutrements\/300000-aberdine-22-x-3-rug-aqua","image_link":"https:\/\/app.onsidedoor.test\/storage\/images\/vendors\/500-surya\/1-aberdine-22-x-3-rug-aqua\/36cb870df093575f1980170f88b760ea.jpg","categories":["Rugs, Mugs, Accoutrements"],"price":60},{"id":1000001,"title":"Adia 8' X 10' Rug, Burnt Orange","description":"Add a touch of rustic elegance to your home with the Adia Collection. The meticulously woven construction of these pieces boasts durability and will provide natural charm into your decor space. Made with Wool in India, and has No Pile. Spot Clean Only, One Year Limited Warranty.","link":"https:\/\/app.onsidedoor.test\/s\/1000\/collections\/20002-rugs-mugs-accoutrements\/300001-adia-8-x-10-rug-burnt-orange","image_link":"https:\/\/app.onsidedoor.test\/storage\/images\/vendors\/500-surya\/2-adia-8-x-10-rug-burnt-orange\/b21abd2f0dfa3ebe13988ced70919891.jpg","categories":["Rugs, Mugs, Accoutrements"],"price":1590},{"id":1000002,"title":"Aesop 9' X 12' Rug, Khaki","description":"The Aesop Collection feautures compelling global inspired designs brimming with elegance and grace! The perfect addition for any home, these pieces will add eclectic charm to any room! The meticulously woven construction of these pieces boasts durability and will provide natural charm into your decor space. Made with Chenille-Polyester, Polyester in Turkey, and has Low Pile. Spot Clean Only, One Year Limited Warranty.","link":"https:\/\/app.onsidedoor.test\/s\/1000\/collections\/20002-rugs-mugs-accoutrements\/300002-aesop-9-x-12-rug-khaki","image_link":"https:\/\/app.onsidedoor.test\/storage\/images\/vendors\/500-surya\/3-aesop-9-x-12-rug-khaki\/1cf81146f1407677dd4a2c7f03d4fd58.jpg","categories":["Rugs, Mugs, Accoutrements"],"price":1015}]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment