Skip to content

Instantly share code, notes, and snippets.

let elements = {
'a': {
'audio': 'sounds/sound.mp3',
'video': 'grass.mp4',
},
'b': {
'audio': 'sounds/sound2.mp3',
'video': 'sun.mp4',
let chords = {
'abc': 'audio/chord-1.mp3',
'def': 'audio/chord-2.mp3',
};
// corresponding <div id="output"></div>
let output = document.querySelector('#output');
// our input element
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
<script src="script.js" charset="utf-8" defer></script>
<style media="screen">
#message-bin {
width: 500px;
let textInput = document.querySelector('#text-input');
let messageBin = document.querySelector('#message-bin');
let nameEntered = false;
let pronounsEntered = false;
let firstLanguage = false;
let cities = {
'a': {
'cityName': 'Amsterdam',
'video': 'videos/amsterdam.mp4',
},
'b': {
'cityName': 'Boston',
'video': 'videos/boston.mp4'
let artists = {
'p': {
'name': 'Pheobe Bridgers',
'img': 'pheobe.png',
'audio': 'song.mp3'
},
'q': {
'name': 'Queen',
<!--
Hi Sophia, here are the changes I made.. no need to include the <style> tags to your css,
just added those here for syntax highlighting here : )
-->
<!-- index.html changes -->
<div id="fold1">
<!--SCROLLING TEXT-->
<div class="scrolling" id="fade-in">
<div class="leftscroll">
@m4rk3r
m4rk3r / presence.js
Last active February 17, 2021 21:58
const Redis = require('ioredis');
const express = require('express');
const app = express();
const http = require('http');
const server = http.createServer(app);
const io = require('socket.io')(server);
const redis = new Redis();
const redisAdapter = require('socket.io-redis');
/**
* Paste the following block into your dev console to average the colors of your favorite fish
* and assign it as your block color (temporarily) : ) 💜🐟
* Bookmarklet: http://duskjacket.com/static/fav-fish/
**/
(function () {
const dec2hex = function (v) { return v.toString(16);};
const hex2dec = function (v) { return parseInt(v, 16);};
const friends = document.querySelectorAll('#friends a');
https://www.youtube.com/watch?v=q96o9AvJO0M,2
https://www.youtube.com/watch?v=pEw3B3E5F6s,3
https://www.youtube.com/watch?v=gq9fGwJ_HQE,39
https://www.youtube.com/watch?v=vyut3GyQtn0,5
https://www.youtube.com/watch?v=n7rfYjgPRiM,5
https://www.youtube.com/watch?v=w-o4pZA0OPM
https://www.youtube.com/watch?v=vcPX0I1sc4I,5
https://www.youtube.com/watch?v=bJSgAOrS3-w,15
https://www.youtube.com/watch?v=PxvjXDAfPhk,15
https://www.youtube.com/watch?v=76E-thr2I14,20