Skip to content

Instantly share code, notes, and snippets.

@kklai
kklai / index.html
Last active March 10, 2021 10:16
sn code block
<style>
.g-body {
max-width: 1200px;
margin: 0 auto;
padding: 0;
width: 100%;
font-family: droid sans, helvetica neue, Helvetica, Arial, sans-serif;
color: #444;
}
.g-kicker {
import Navbar from '../components/navbar.components'
import Head from 'next/head'
import topstory from "../styles/topstory.module.scss"
import Link from 'next/link'
import LocationOnIcon from '@mui/icons-material/LocationOn';
export default function Home({story}) {
console.log(story.data)
return (
// importing data
import { onMount } from 'svelte';
onMount(async() => {
const res = await fetch(`/tutorial/api/album`);
photos = await res.json();
console.log(photos)
})
freq = 1;
amp = 110;
loopTime = 3;
t = time % loopTime;
wiggle1 = wiggle(freq, amp, 1, 0.5, t);
wiggle2 = wiggle(freq, amp, 1, 0.5, t - loopTime);
linear(t, 0, loopTime, wiggle1, wiggle2)
document.querySelectorAll(".ad__section-border").forEach(e => e.remove());
document.querySelectorAll(".article-content__sign-in-group").forEach(e => e.remove());
document.querySelectorAll(".article-content__widget-group").forEach(e => e.remove());
document.querySelectorAll(".featured-video").forEach(e => e.remove());