Skip to content

Instantly share code, notes, and snippets.

View whereispolaris's full-sized avatar
🕶️
Obsessed with JS

Santiago Enciso whereispolaris

🕶️
Obsessed with JS
View GitHub Profile
@whereispolaris
whereispolaris / extend-product-registration.liquid
Created March 11, 2024 20:19
Extend Product Registration Script
<script defer>
// Run scripts on DOMContentLoaded to avoid affecting site load time
window.addEventListener('DOMContentLoaded', function () {
const productCardTemplate = document.querySelector("[data-product-template]");
const productCardContainer = document.querySelector("[data-products-cards-container]");
const prodSearch = document.getElementById('prodSearch');
const mainForm = document.getElementById('mainForm');
const searchInput = document.querySelector("#prodSearchText");
const productSearchBtn = document.getElementById('productSearchBtn');
@whereispolaris
whereispolaris / page.product-registration.liquid
Created March 11, 2024 20:17
Extend Product Registration Page Template
<div class="container container--narrow">
<header class="page__header page__header--centered">
<h1 class="page__title heading h1">{{ page.title }}</h1>
</header>
<h3 style="text-align: -webkit-center;"><strong>Contact Information</strong></h3>
<div id="contact-info-container">
<div class="row" id="name-wrapper">
<div class="field__input-wrapper" style="margin-right: 5px;">
<label class="input-label" for="pr-first">First Name<span class="req"> *</span></label>

Thermomix - Hide Extend Offers For Bundled Products

Below are the instructions needed to hide extend offers in bundled products

  1. create a custom JavaScript file named extend-hide-offers.js in the root of the Storefront Child theme and add the following snippet:
jQuery(document).ready(function(){
 // Hides offers in PDP bundle

Shopify Headless Integration Guide

This guide will walk you through the steps to integrate Extend on a headless Shopify store.

Summary

  • Initialize Shopify Client
  • Creating/Fetching Checkout
  • Adding the Extend SDK
  • Rendering Offers
  • Add To Cart Logic
/**
* This is a collection of commonly used snippets for headless Shopify integrations with Extend
* You will need to utilize 2 SDK's with headless shopify integrations
* 99% of the used SDK's will be the Extend JS SDK: https://helloextend.github.io/extend-sdk-client/
* You will only need to use 1 method from our ShopifySDK in a headless integration: https://helloextend.github.io/client-integrations/extend-shopify-sdk
* The one method you will be using from the Extend ShopifySDK is ExtendShopify.getPlanVariant which will simply be used to retrieve
*
* Extend SDK Documentation: https://helloextend.github.io/extend-sdk-client/
* Extend Shopify SDK Documentation: https://helloextend.github.io/client-integrations/extend-shopify-sdk.html#api-reference
**/
const puppeteer = require('puppeteer');
async function getItems() {
// Launches browser
const browser = await puppeteer.launch({
// Show Chromium browser
headless: false,
// fix viewport bug
defaultViewport: null,
});

WPE Support L1: Topics To Look Up

Terminal

  • DNS (Domain Name System) - A Records, CNAME Records
  • SSL Certificates
  • Linux (Terminal, Command line, CLI)
  • HTTP/HTTPS (Hypertext Transfer Protocol)
  • SSH (Secure Shell) - How we connect to servers
  • FTP/SFTP (Secure File Transfer Protocol) - FileZilla is one of many tools to connect via FTP/SFTP
import React, { Component } from 'react';
class InputForm extends Component {
state = {
value: ''
};
handleValueChange = e => {
this.setState({ value: e.target.value });
console.log(this.state.value);