Skip to content

Results for “javascript”

14 prompts

Set up a monorepo for [apps and packages, e.g. web app, API and shared UI library] using [tool, e.g. pnpm workspaces / Turborepo / Nx]. Show the folder structure, config files, shared TypeScript config, build and test scripts, and CI caching.

ChatGPT
Coding & Development

Monorepo setup

Organises multiple apps and packages in one repository.

0

Write a React custom hook called [useSomething] that [purpose, e.g. fetches data with caching / debounces input / tracks window size]. Use TypeScript, handle cleanup and errors, and include usage examples and tests.

ChatGPT
Coding & Development

React custom hook

A reusable custom hook with clean state management.

0

Build validation for a [form type] form in [framework or vanilla JS]. Validate [fields] on blur and submit, show inline accessible error messages, disable submit while sending, and handle server-side errors gracefully.

ChatGPT
Coding & Development

Form validation on the frontend

Accessible form validation with helpful error messages.

0

Write a Node.js script that [task, e.g. reads a CSV and calls an API for each row]. Use async/await, limit concurrency to [n], retry failed requests with backoff, log progress, and handle errors without crashing. Include package.json dependencies.

ChatGPT
Coding & Development

Node.js script with async/await

A clean Node.js script with proper async error handling.

0

Refactor this callback-based code to use async/await. Keep the behaviour identical, add proper try/catch error handling, and explain any changes in execution order. Code: [paste code]

ChatGPT
Coding & Development

Convert callbacks to async/await

Modernises callback-based code to promises and async/await.

0

Write Jest unit tests for this function/module. Cover normal cases, edge cases, error handling, and mock [dependencies]. Use descriptive test names and arrange-act-assert structure. Code: [paste code]

ChatGPT
Coding & Development

Unit tests in Jest

Thorough Jest tests with mocks and edge cases.

0

You are a bot developer. Platform: [Discord / Telegram] Language: [Python / JavaScript] Features: [commands, welcome messages, reminders, polls, moderation] Write the bot with a clear structure, command handlers, permission checks, error handling, and environment variables for the token (names only). Include setup ste…

Claude
Coding & Development

Discord or Telegram bot

Build a simple community bot with commands, moderation helpers or notifications.

0

Act as a JavaScript expert. What should happen: [expected behaviour] What actually happens: [bug] Code: ```js [paste] ``` Explain the async flow step by step, identify the bug (race condition, missing await, unhandled rejection, etc.), provide fixed code, and suggest patterns to prevent it (Promise.all, AbortControlle…

ChatGPT
Coding & Development

Debug async JavaScript

Fix race conditions, unhandled promises and ordering bugs in async JavaScript.

0

[Attach a screenshot or design image] You are a front-end developer. Recreate this design as HTML and CSS. Requirements: - Semantic HTML5 and accessible markup (alt text, labels, contrast) - Responsive: mobile first, with breakpoints at [e.g. 640px, 1024px] - Styling with [plain CSS with variables / Tailwind] - Match…

Claude
Coding & Development

Turn a screenshot or design into HTML and CSS

Upload a mockup or screenshot and get responsive, semantic HTML and CSS that matches it closely.

0

Act as a Python developer. Website: [URL or type of site] Data to extract: [fields] Pages: [single page / pagination / list of URLs] Output: [CSV / JSON] Write a script using requests + BeautifulSoup (or Playwright if the page needs JavaScript) that: - Respects robots.txt and adds a delay between requests - Sets a cle…

ChatGPT
Coding & Development

Python web scraper

Build a polite, robust web scraper that extracts structured data and saves it to CSV or JSON.

0

You are a browser extension developer. Extension idea: [what it does] Where it runs: [all sites / specific domains] UI: [popup, options page, sidebar] Data to store: [settings, lists] Create a Manifest V3 extension with: 1. manifest.json with minimal permissions 2. popup.html/js/css 3. content script and/or service wo…

Claude
Coding & Development

Chrome extension starter

Generate a working Manifest V3 Chrome extension with popup, content script and storage for your idea.

0

You are a senior front-end developer and designer. Build a single-file landing page using HTML and Tailwind CSS (via CDN). Product: [name and what it does] Audience: [who it's for] Brand colours: [hex codes] Style: [e.g. minimal, bold, playful, dark mode] Sections: hero with headline + CTA, logos/social proof, 3 featu…

Claude
Coding & Development

Responsive landing page in HTML and Tailwind CSS

Generate a modern, responsive, accessible landing page as a single HTML file using Tailwind, ready to customise and deploy.

0