Skip to content

Instantly share code, notes, and snippets.

View alexvdvalk's full-sized avatar

Alex van der Valk alexvdvalk

View GitHub Profile
@alexvdvalk
alexvdvalk / hide 'create opportunity' field.ts
Last active December 12, 2025 15:02
hide 'create opportunity' field.ts
// Create page interaction
// Page = "record"
// Action = "Modify Tabs"
// Enabled = true
// This page interaction will hide some opportunity related fields leads / elements.
// Run on the overview tab, which means this will run once when the entity page loads
if (item.label !== "TABS.OVERVIEW") return;
@alexvdvalk
alexvdvalk / external request page interaction.ts
Created October 20, 2025 09:37
Make external API request from a Bullhorn page interaction
const url =
"https://meetup.trycloudflare.com"; // update with your endpoint
const a = async()=> { // Javascript promise
const response = await fetch (url, {
method: 'POST',
body: JSON.stringify(form.data)
})
const data = await response.json();
console.log('data', data);
@alexvdvalk
alexvdvalk / +page.svelte
Created June 15, 2023 14:04
Sveltekit Directus Websockets Demo
<script lang="ts">
import { onMount } from 'svelte';
const url = 'ws://localhost:8055/websocket';
const access_token = 'your key';
const collection = 'posts';
onMount(() => {
const connection = new WebSocket(url);
connection.addEventListener('open', function () {