bsky_rss_pollmain.tsx2 matches
1import { rss_to_bsky } from "https://esm.town/v/jordan/rss_to_bsky";
2import { blob } from "https://esm.town/v/std/blob";
3import { fetch } from "https://esm.town/v/std/fetch";
45export async function bsky_rss_poll() {
6const { parseFeed } = await import("https://deno.land/x/rss/mod.ts");
7const res = await fetch("https://v8.dev/blog.atom")
8.then(res => res.text())
9.then(res => parseFeed(res));
slackScoutmain.tsx8 matches
20for (const topic of KEYWORDS) {
21const results = await Promise.allSettled([
22fetchHackerNewsResults(topic),
23fetchTwitterResults(topic),
24fetchRedditResults(topic),
25]);
2649}
5051// Fetch Hacker news, Twitter, and Reddit results
52async function fetchHackerNewsResults(topic: string): Promise<Website[]> {
53return hackerNewsSearch({
54query: topic,
58}
5960async function fetchTwitterResults(topic: string): Promise<Website[]> {
61return twitterSearch({
62query: topic,
67}
6869async function fetchRedditResults(topic: string): Promise<Website[]> {
70return redditSearch({ query: topic });
71}
84}
8586const response = await fetch(slackWebhookUrl, {
87method: "POST",
88headers: { "Content-Type": "application/json" },
12* @param {number} [opts.timeout=10 minutes] - The maximum amount of time (in milliseconds) the client will wait for a response before timing out.
13* @param {number} [opts.httpAgent] - An HTTP agent used to manage HTTP(s) connections.
14* @param {Core.Fetch} [opts.fetch] - Specify a custom `fetch` function implementation.
15* @param {number} [opts.maxRetries=2] - The maximum number of times the client will retry a request.
16* @param {Core.Headers} opts.defaultHeaders - Default headers to include with every request to the API.
reqEvaltownmain.tsx1 match
32const url = new URL("." + pathname, "http://localhost:" + port);
33url.search = search;
34const resp = await fetch(url, {
35method: req.method,
36headers: req.headers,
valtowntownmain.tsx1 match
174});
175176export default app.fetch.bind(app);
177178const css = `
blob_adminmain.tsx2 matches
1/** @jsxImportSource https://esm.sh/hono@4.0.8/jsx **/
23import { modifyFetchHandler } from "https://esm.town/v/andreterron/codeOnValTown?v=50";
4import view_route from "https://esm.town/v/pomdtr/blob_admin_blob";
5import create_route from "https://esm.town/v/pomdtr/blob_admin_create";
154155// Update the export statement
156export default modifyFetchHandler(app.fetch);
elegantJadeParrotfishmain.tsx4 matches
1213async function archive(url: string) {
14const response = await fetch(url);
15const body = await response.text();
16const $ = load(body);
51<h3>DDL UTILITY v0.0.1b</h3>
52<code>
53This site fetches content from another site,if any links dosent work then the movie is probably not uploaded.
54</code>
55<input type="text" placeholder="IMDB ID" name="imdb" />
67const url = new URL(atob(c.req.query("id")));
68if ((url.hostname) !== "www.primewire.tf") throw new Error("Error...");
69const req = await fetch(url, { method: "HEAD", redirect: "manual" });
70const realURL = await req.headers.get("location");
71const newURL = new URL(realURL);
344// getSourcesParams.append("h", kid);
345// getSourcesParams.append("b", browserid);
346// const result = await fetch(
347// `https://rabbitstream.net/ajax/v2/embed-4/getSources?${getSourcesParams.toString()}`,
348// {
verbalScarletAntelopemain.tsx12 matches
60}, [state.loading, state.hasMore]);
6162const fetchStories = async () => {
63try {
64const response = await fetch("/api/stories");
65if (!response.ok) throw new Error("Failed to fetch dates");
66const data = await response.json();
67setStories(data);
69}
70catch (err) {
71console.error("Error fetching stories:", err);
72}
73};
7475const fetchComments = async (query: string, story: string, page: number) => {
76try {
77dispatch({ type: "loading", value: true });
78const response = await fetch(`/api/comments?query=${encodeURIComponent(query)}&story=${story}&page=${page}`);
79if (!response.ok) throw new Error("Failed to fetch comments");
80const data = await response.json();
81setComments(prevComments => page === 1 ? data.hits : [...prevComments, ...data.hits]);
84dispatch({ type: "loading", value: false });
85} catch (err) {
86console.error("Error fetching comments:", err);
87dispatch({ type: "loading", value: false });
88}
99dispatch({ type: "hasMore", value: true });
100dispatch({ type: "query", value: newQuery });
101fetchComments(fullQuery, state.story, 1);
102};
103104useEffect(() => {
105fetchStories();
106107const handleScroll = () => {
122: "";
123const fullQuery = `${filtersQuery} ${state.query}`;
124fetchComments(fullQuery, state.story, state.page);
125}
126}
408tags: `comment, story_${story}`,
409page: 0,
410hitsPerPage: 100, // Fetch a moderate number of comments
411});
412
forbearingOrangePlatypusmain.tsx2 matches
3536async function execute(statement: InStatement, args?: InArgs): Promise<ResultSet> {
37const res = await fetch(`${API_URL}/v1/sqlite/execute`, {
38method: "POST",
39headers: {
5051async function batch(statements: InStatement[], mode?: TransactionMode): Promise<ResultSet[]> {
52const res = await fetch(`${API_URL}/v1/sqlite/batch`, {
53method: "POST",
54headers: {
3536async function execute(statement: InStatement, args?: InArgs): Promise<ResultSet> {
37const res = await fetch(`${API_URL}/v1/sqlite/execute`, {
38method: "POST",
39headers: {
5051async function batch(statements: InStatement[], mode?: TransactionMode): Promise<ResultSet[]> {
52const res = await fetch(`${API_URL}/v1/sqlite/batch`, {
53method: "POST",
54headers: {