yeh-yeh-CO-ah in Nahuatl means to try something; to try or experiment with something; to rehearse;
This is our own spin on the Vue Playground. Originally intended to be used within a TutorialKit (tk in this readme to save some keystrokes) preview window.
Most notably, it doesn't allow for switching Vue versions nor it displays the compiled code. Since this will be focused (at least at first) on the basic concepts, we don't want all of that.
As part of amoxtli-vue
This is the playground that will load into a preview pane in the amoxtli-vue project.
It reads the different code files in the lessons provided from that repo and loads them into the monaco editor to interact with them.
An npm task is available for when you want to see your changes embedded into the tk project:
# build and install on tk project
npm biThis will first build the project and then copy the required contents from the /dist folder into the amoxtli-vue/src/templates/yehyecoa/ folder.
Note
Take a look at amoxtli-vue/src/templates/yehyecoa/server.js as it contains logic to notify yehyecoa-vue when the contents of the file have been updated. This is if you want to dynamically update the contents of the editor (and thus perfect for embedding into a tk webcontainer).
-
Node.js: Version 24.5.0 (exact version specified in
.node-versionfile andenginesfield)Recommended: Use fnm to manage Node.js versions:
# Install fnm (if not already installed) curl -fsSL https://fnm.vercel.app/install | bash # Use the project's Node.js version (reads .node-version automatically) fnm use # Or install and use the specific version fnm install 24.5.0 fnm use 24.5.0
-
pnpm: Version 10.17.0 (specified as packageManager)
npm install -g [email protected]
VSCode + Volar (and disable Vetur) + ESLint + UnoCSS
- Vue.volar - Vue language support
- dbaeumer.vscode-eslint - ESLint integration
- antfu.unocss - UnoCSS IntelliSense
- bradlc.vscode-tailwindcss - TailwindCSS IntelliSense (for CSS utilities)
- Vue.vscode-typescript-vue-plugin - Vue TypeScript support
This is a pnpm workspace with multiple packages:
- Root: Main Vue application with real-time collaboration
packages/party-kit/: PartyKit server for WebSocket communicationpackages/vue-repl/: Enhanced Vue REPL component (forked from @vue/repl)packages/shared-types/: Shared TypeScript types
-
Clone and install dependencies:
git clone <repository-url> cd yehyecoa-vue pnpm install
-
Install dependencies for all workspace packages:
# This installs dependencies for all packages in the workspace pnpm install --recursive
For complete real-time collaboration features, you need both the main app and PartyKit server:
-
Start the PartyKit server (in a separate terminal):
cd packages/party-kit pnpm devThis starts the WebSocket server at
http://localhost:1999 -
Start the main application (in another terminal):
# From project root pnpm devThis starts the Vue app at
http://localhost:5173
If you're only working on UI components and don't need real-time features:
pnpm devNote
Without the PartyKit server, collaboration features will be disabled but the REPL will still function as a standalone editor.
If you're modifying the core REPL functionality:
cd packages/vue-repl
pnpm devpnpm dev- Start development server with hot reloadpnpm build- Build for production (includes all optimizations)pnpm preview- Preview production buildpnpm type-check- Run TypeScript type checkingpnpm lint- Lint the main packagepnpm lint:all- Lint all packages in workspacepnpm lint:fix- Auto-fix linting issues
pnpm bi- Build and Install: Build project and copy to amoxtli-vuepnpm sync:vue-repl- Sync with upstream vue-repl forkpnpm sync:party-kit- Sync with upstream party-kit fork
The project uses:
- UnoCSS for utility-first CSS with multiple presets
- Monaco Editor for code editing with TypeScript support
- Pinia for state management
- PartyKit for real-time WebSocket communication
- Vite for build tooling and development server
TypeScript cannot handle type information for .vue imports by default, so we replace the tsc CLI with vue-tsc for type checking. In editors, we need Volar to make the TypeScript language service aware of .vue types.
# Run tests for party-kit package
cd packages/party-kit
pnpm test
# Run tests with coverage
pnpm test:coverage- Node version mismatch: Ensure you're using Node.js 24.5.0+
- pnpm version issues: Use the exact version specified (
10.17.0) - WebSocket connection fails: Make sure PartyKit server is running on port 1999
- Monaco Editor not loading: Check that workers are properly bundled (handled by build scripts)
If you encounter issues with workspace packages:
# Clean and reinstall all dependencies
pnpm clean
rm -rf node_modules packages/*/node_modules
pnpm install
# Rebuild all packages
pnpm -r run buildpnpm buildThis will:
- Type-check all files
- Build the main application
- Minify workers and assets
- Build the server component
- Compress assets for optimal loading
pnpm biThis builds the project and copies the distribution files to the amoxtli-vue template directory.

