Skip to content

Instantly share code, notes, and snippets.

View Cerberus's full-sized avatar

Cerberus Cerberus

View GitHub Profile
@simenbrekken
simenbrekken / README.md
Last active November 9, 2023 16:56
Hide fetch/XHR in Cypress command log

This novel workaround simply hides any command log entries that originate from fetch/XHR requests.

While I've updated this receipe for Cypress 10 and converted it to TypeScript you should be able to use it in a JavaScript project by ignoring the cypress.d.ts file and placing the snippet from e2e.ts in e2e.js instead.

@larrybeall
larrybeall / gist:67a71750e36867d4f4b927914288f542
Last active March 22, 2020 21:58
A very rough React Component wrapper for the Cloudflare stream element...
import React, { useEffect, useRef } from 'react';
const StreamWrapper = ({ source, height, width, autoplay }) => {
const target = useRef(() => null);
useEffect(() => {
if (!target.current) return;
window.__stream.initElement(target.current);
});
return (