Skip to content

Instantly share code, notes, and snippets.

View VonStruddle's full-sized avatar
🕶️
Doing stuff on the interwebs

Quentin Durantay VonStruddle

🕶️
Doing stuff on the interwebs
View GitHub Profile
@VonStruddle
VonStruddle / supabase-weweb.js
Created January 11, 2024 14:42
Supabase WeWeb
// Code to download
const path = variables[/* public - value */ '6a7181eb-2a13-4bd8-ba04-fc8f48e62d0e-value']?.['name'] // replace by your variable
const { data, error } = await wwLib.wwPlugins.supabase.instance.storage
.from('bucket_public')
.upload(path, variables[/* public - value */ '6a7181eb-2a13-4bd8-ba04-fc8f48e62d0e-value'], {upsert:true}) // replace by your variable
if (error) throw error
return data
// End
@VonStruddle
VonStruddle / action.js
Created August 22, 2023 15:56
Download file WeWeb
const link = wwLib.getFrontDocument().createElement('a');
const fileName = context.item.data?.['summary']?.['name']; // replace by your file name
const apiUrl = context.item.data?.['summary']?.['url']; // replace by your file URL
link.href = apiUrl;
link.download = fileName;
wwLib.getFrontDocument().body.appendChild(link);
fetch(apiUrl, {
@VonStruddle
VonStruddle / automation.js
Last active October 19, 2022 08:36
Airtable / Xano CDN automation
const xanoBaseUrl = 'https://xc0b-vcze-d4we.n7.xano.io' // Edit this variable to match your Xano instance subdomain
let table = base.getTable('property')
let config = input.config()
let recordId = config.updatedRecordId
let record = await table.selectRecordAsync(recordId, {fields: table.fields})
let images = record.getCellValue('images') // Update this value to match your image/file attachment column
let imagesUrlCdn = []
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH=/Users/ungrim/.oh-my-zsh
# Set name of the theme to load. Optionally, if you set this to "random"
# it'll load a random theme each time that oh-my-zsh is loaded.
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
ZSH_THEME="agnoster"
// Sticky Plugin v1.0.4 for jQuery
// =============
// Author: Anthony Garand
// Improvements by German M. Bravo (Kronuz) and Ruud Kamphuis (ruudk)
// Improvements by Leonardo C. Daronco (daronco)
// Created: 02/14/2011
// Date: 07/20/2015
// Website: http://stickyjs.com/
// Description: Makes an element on the page stick on the screen as you scroll
// It will only set the 'top' and 'position' of your element, you
window.mr = window.mr || {};
mr = (function (mr, $, window, document){
"use strict";
mr = mr || {};
var components = {documentReady: [],documentReadyDeferred: [], windowLoad: [], windowLoadDeferred: []};
/*! Copyright (c) Go Make Things, LLC
https://github.com/cferdinandi/smooth-scroll
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
/*!
* jQuery - Spectragram by Adrian Quevedo
* http://adrianquevedo.com/ - http://lab.adrianquevedo.com/ - http://elnucleo.com.co/
*
* Dual licensed under the MIT or GPL Version 2 licenses.
* You are free to use this plugin in commercial projects as long as the copyright header is left intact.
*
* This plugin uses the Instagram(tm) API and is not endorsed or certified by Instagram or Burbn, inc.
* All Instagram(tm) logos and trademarks displayed on this plugin are property of Burbn, Inc.
*
/*********************************************************************
* #### Twitter Post Fetcher v17.0.0 ####
* Coded by Jason Mayes 2015. A present to all the developers out there.
* www.jasonmayes.com
* Please keep this disclaimer with my code if you use it. Thanks. :-)
* Got feedback or questions, ask here:
* http://www.jasonmayes.com/projects/twitterApi/
* Github: https://github.com/jasonmayes/Twitter-Post-Fetcher
* Updates will be posted to this site.
*********************************************************************/
/*!
* The Final Countdown for jQuery v2.2.0 (http://hilios.github.io/jQuery.countdown/)
* Copyright (c) 2016 Edson Hilios
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions: