Skip to content

Instantly share code, notes, and snippets.

View agungjk's full-sized avatar

Agung Jati Kusumo agungjk

View GitHub Profile
@agungjk
agungjk / [slug].js
Last active February 9, 2024 12:48
Crawler example on Vercel using Puppeteer and NextJS API routes
const puppeteer = require('puppeteer-core');
const cheerio = require('cheerio');
const chrome = require('chrome-aws-lambda');
export default async (req, res) => {
const slug = req?.query?.slug;
if (!slug) {
res.statusCode = 200
res.setHeader('Content-Type', 'application/json')
res.end(JSON.stringify({ id: null }))
@agungjk
agungjk / ScrollingTextView.swift
Created April 6, 2021 11:43 — forked from NicholasBellucci/ScrollingTextView.swift
MacOS swift marquee scrolling text view
import Cocoa
open class ScrollingTextView: NSView {
// MARK: - Open variables
/// Text to scroll
open var text: NSString?
/// Font for scrolling text
open var font: NSFont?