You can access search results via JSON API by adding format=json
to your query:
https://codesearch.val.run/...?q=function&page=2&format=json
For typeahead suggestions, use the /typeahead
endpoint:
https://codesearch.val.run/typeahead?q=function
Returns an array of strings in format "username" or "username/projectName"
Found 30427 results for "function"(1906ms)
22readResource: (serverName: string, uri: string) => Promise<string>;
2324// Utility functions
25log: (level: "debug" | "info" | "warning" | "error", message: string, data?: any) => void;
2640* - Handles iframe communication via postMessage
41*/
42export default function HTMLRenderer({ html, mcpClients = [], className = "" }: HTMLRendererProps) {
43const iframeRef = useRef<HTMLIFrameElement>(null);
44const containerRef = useRef<HTMLDivElement>(null);
132},
133134// Utility functions
135log: (level: "debug" | "info" | "warning" | "error", message: string, data?: any) => {
136console[level](`[HTMLRenderer] ${message}`, data);
154}, [mcpClients, isFullscreen]);
155156// Fullscreen functionality
157const enterFullscreen = useCallback(() => {
158const container = containerRef.current;
218const methodFunc = (mcpContext as any)[method];
219220if (typeof methodFunc !== "function") {
221throw new Error(`Unknown MCP API method: ${method}`);
222}
365<script>
366// Update fullscreen controls based on state
367async function updateFullscreenControls() {
368const controls = document.getElementById('fullscreenControls');
369const isFs = await window.mcpContext.isFullscreen();
54**Context Data:** The user's projects and tasks will be provided in a JSON string following their message.`;
5556function generateHtmlShell(sourceUrl: string): string {
57return `
58<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>AuraTask - AI Todo</title>
75<template id="review-task-template"><div class="review-task-item"><input type="text" class="review-task-content" placeholder="Task description" required><input type="date" class="review-task-due-date" title="Due Date"><select class="review-task-load" title="Cognitive Load"><option value="Low">Low</option><option value="Medium" selected>Medium</option><option value="High">High</option></select><button type="button" class="review-task-delete-btn" title="Remove Task">×</button></div></template>
76<script>
77(function() {
78const API_URL = '${sourceUrl}';
79const STORE_KEYS = { projects: 'aura_projects_v1', tasks: 'aura_tasks_v1' };
86const genId = () => Date.now().toString(36) + Math.random().toString(36).substr(2, 9);
87
88function checkTaskLoad() {
89if (tasks.filter(t => !t.isCompleted).length >= ACTIVE_TASK_WARNING_THRESHOLD) {
90return confirm("You have a lot of active tasks. Are you sure you want to add more? It might be a good time to complete some items first.");
93}
9495function loadState() {
96projects = getStore(STORE_KEYS.projects);
97tasks = getStore(STORE_KEYS.tasks);
102}
103104function render() {
105renderSidebar();
106renderTaskList();
108}
109110function toggleLoading(btn, show) {
111if (!btn) return;
112btn.disabled = show;
114}
115116function updateUIElements() {
117const todayStr = new Date().toISOString().split("T")[0];
118const todayTasks = tasks.filter(t => !t.isCompleted && t.dueDate === todayStr);
128}
129130function renderSidebar() {
131const mainViews = [
132{id:'today',name:'Today',icon:'M6 2a1 1 0 00-1 1v1H4a2 2 0 00-2 2v10a2 2 0 002 2h12a2 2 0 002-2V6a2 2 0 00-2-2h-1V3a1 1 0 10-2 0v1H7V3a1 1 0 00-1-1z'},
137}
138139function renderTaskList() {
140const container = $("#task-list");
141let filteredTasks = [], title = 'Tasks';
160}
161162function renderChatLog() {
163const log = $("#chat-log");
164log.innerHTML = conversationHistory.map((msg, idx) => {
172}
173174function addMessageToChat(sender, text, plan = null, requiresConfirmation = false) {
175conversationHistory.push({ sender, text, plan, requiresConfirmation });
176renderChatLog();
177}
178179function executePlan(plan) {
180plan.forEach(action => {
181if (action.operation === 'CREATE_TASK') {
193}
194195function handleAddTask(e) {
196e.preventDefault();
197if (!checkTaskLoad()) return;
206}
207208function handleTaskClick(e) {
209const target = e.target, taskItem = target.closest(".task-item");
210if (!taskItem) return;
225}
226227function openEditModal(task) {
228$("#edit-task-id").value = task.id;
229$("#edit-task-content").value = task.content;
234}
235236function handleUpdateTask(e) {
237e.preventDefault();
238const taskId = $("#edit-task-id").value, task = tasks.find(t => t.id === taskId);
247}
248249async function handleChatSubmit(e) {
250e.preventDefault();
251const input = $("#chat-input"), userMessage = input.value.trim();
270}
271272function handlePlanConfirm(e) {
273const action = e.target.dataset.planAction, idx = e.target.dataset.planIdx;
274if (!action || !idx) return;
279}
280281async function triggerProjectSynthesis() {
282if (!checkTaskLoad()) return;
283const goal = $("#synthesis-goal-input").value.trim();
302}
303304function addReviewTaskRow(taskData = {}) {
305const template = $('#review-task-template');
306const clone = template.content.cloneNode(true);
313}
314315function openProjectReviewModal(data) {
316const { projectName, tasks: aiTasks } = data;
317$('#review-project-name').value = projectName;
322}
323324function handleProjectReviewSubmit(e) {
325e.preventDefault();
326const projectName = $('#review-project-name').value.trim();
353}
354355async function triggerDailyRebalance() {
356const todayStr = new Date().toISOString().split("T")[0];
357const todayTasks = tasks.filter(t => !t.isCompleted && t.dueDate === todayStr);
385}
386387function bindEventListeners() {
388document.body.addEventListener('click', e => {
389if (e.target.closest('[data-view]')) {
419}
420421export default async function(req: Request): Promise<Response> {
422const openai = new OpenAI();
423const url = new URL(req.url);