Skip to content

Instantly share code, notes, and snippets.

View howyay's full-sized avatar
🏠
Working from home

howyay

🏠
Working from home
  • Hunan, China & NY/CA, US
View GitHub Profile
@howyay
howyay / worker.js
Last active April 6, 2020 15:16 — forked from tobiaslins/worker.js
Notion.so Custom Domain + Inline LaTeX Rendering
const MY_DOMAIN = "YOUR_DOMAIN"
const START_PAGE = "URL_TO_NOTION_LANDING_PAGE"
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request))
})
const corsHeaders = {
"Access-Control-Allow-Origin": "*",
"Access-Control-Allow-Methods": "GET, HEAD, POST,PUT, OPTIONS",