Alex Gleason af2436a3b8 Handle bare CSS @import specifiers for Tailwind v4
Tailwind v4 projects typically include `@import "tailwindcss";` in
their CSS entry and often `@import` third-party CSS plugins like
`tw-animate-css`. Both cases were broken:

1. esbuild tried to resolve `tailwindcss` through the ESM CDN as JS,
   producing 'Cannot import <...> into a CSS file'. The existing
   CSS-importer guard used `new URL(args.importer)` to detect CSS
   importers, but esbuild passes fs-namespace importers as plain paths
   (e.g. `/projects/foo/src/index.css`) which don't parse as URLs, so
   the guard never fired.

2. `@tailwindcss/browser@4` only resolves a hardcoded set of `@import`
   specifiers (`tailwindcss`, `tailwindcss/preflight`,
   `tailwindcss/theme`, `tailwindcss/utilities`) and throws
   'The browser build does not support @import for <x>' for everything
   else, so plugin packages couldn't be preserved as external either.

Detect CSS importers with a plain string match and split behavior:
`tailwindcss` and its subpaths stay external so the v4 runtime can
handle them, while other bare CSS imports fall through to the normal
esm.sh resolution path. esm.sh redirects CSS-only packages to their
`.css` entry and `onLoad` picks `loader: "css"` via the content-type
mapping, so the dependency is bundled inline. The combined CSS then
lands in the `<style type="text/tailwindcss">` block where the v4
runtime can process v4 directives (`@custom-variant`, `@theme`, etc.)
from third-party plugins.
2026-04-26 22:17:14 -05:00
2025-09-08 15:25:31 -05:00
2025-10-04 17:01:41 -05:00
2026-04-25 18:06:46 -05:00
2025-08-21 13:34:58 -05:00
2026-04-25 18:06:46 -05:00
2026-04-03 16:09:05 -05:00
2025-11-13 19:20:53 -06:00
2025-09-19 19:31:17 -05:00
2026-04-25 18:06:46 -05:00
2025-11-13 21:23:12 -06:00
2026-01-21 14:46:11 -06:00

Shakespeare 🎭

Edit with Shakespeare

Shakespeare is an open-source AI app builder that runs entirely in your browser.

https://shakespeare.diy

Features

  • Use any AI provider OpenAI, Anthropic, OpenRouter, xAI, ZAI, Deepseek, and more
  • Buy credits anonymously with Nostr and Lightning ⚡
  • Redeem gift cards with shareable links for instant credits
  • Runs entirely in the browser No backend required

How it Works

Shakespeare is a React PWA that stores files in IndexedDB with LightningFS. Your browser connects directly to AI providers and git services (through isomorphic-git) to enable you to build and deploy AI apps entirely from your device.

Shakespeare hosts no backend (except for a couple microservices in the services/ directory; these are fully configurable within Shakespeare's settings). All your code and configuration is stored in your browser.

Configure any AI providers and git services you want. Configuration is stored entirely in the browser in localStorage.

You can then push and pull code to syncronize your work across devices.

Shakespeare can work on any type of project. But it is specialized to build React applications in TypeScript, which it compiles in the browser with esbuild-wasm and custom plugins. Any codebase can be worked on, but only compatible projects can be previewed directly in Shakespeare.

Open Source

Shakespeare is proudly Open Source software licensed under the GNU AGPLv3. The purpose of Shakespeare is to provide a free and open platform for building AI applications that respects user privacy and freedom.

Mirrors

Shakespeare is available on the following URLs:

Alternatives

  • goose - open-source desktop app and cli utilizing your full computer for AI tasks
  • bolt.diy - similar to Shakespeare, but built on closed-source WebContainers technology
S
Description
No description provided
Readme AGPL-3.0
11 MiB
0 Stars 1 Watchers 0 Forks
Languages
TypeScript 99.3%
JavaScript 0.2%
Shell 0.2%
CSS 0.2%