A comprehensive, reusable devcontainer specifically designed for TypeScript development focused on Microsoft Excel applications. This environment provides everything you need to build Excel Add-ins, function builders, games, and other Office applications.
- Complete TypeScript Development Stack: Node.js 20, TypeScript 5.0+, and modern JavaScript tooling
- Office.js Integration: Full Office.js SDK with TypeScript definitions
- Excel-Specific Tools: Specialized tools for Excel Add-in development
- Modern Build Tools: Webpack, Rollup, and other modern bundlers
- Comprehensive Testing: Jest and Playwright for unit and integration testing
- Code Quality Tools: ESLint, Prettier, and automated formatting
- Ready-to-Use Templates: Pre-built templates for common Excel applications
- VS Code Integration: Optimized extensions and settings for Office development
- Gitpod Support: Full cloud development environment with one-click setup
- Windows 11 + WSL2: Optimized for Windows 11 with WSL2 development
- Interactive Helper Script: Command-line tool for project management and automation
DevContainer/
βββ Dockerfile # Multi-stage Docker build
βββ devcontainer.json # VS Code devcontainer configuration
βββ README.md # This file
.gitignore # Git ignore rules
.gitattributes # Line ending normalization
.dockerignore # Docker build optimization
examples/ # Example projects and demos
βββ excel-addin-basic/ # Basic Excel Add-in example
βββ excel-function-builder/ # Excel function builder example
βββ excel-game/ # Excel game example
templates/ # Project templates
βββ excel-addin-basic/ # Basic Excel Add-in template
βββ excel-function-builder/ # Excel function builder template
βββ excel-game/ # Excel game template
docs/ # Documentation
βββ getting-started.md # Getting started guide
βββ api-reference.md # API reference
βββ troubleshooting.md # Troubleshooting guide
βββ gitpod-setup-guide.md # Gitpod setup guide for Windows 11 + WSL2
scripts/ # Utility scripts
βββ setup-project.sh # Project setup script
βββ build-all.sh # Build all projects script
βββ test-all.sh # Test all projects script
βββ setup-gitpod-windows.sh # Gitpod setup for Windows 11 + WSL2
βββ gitpod-setup.sh # Gitpod environment setup
βββ gitpod-test.sh # Gitpod configuration test
New to this environment? Use our helper script:
# Interactive menu with all options
./scripts/excel-dev-helper.sh
# Or create a project directly
./scripts/excel-dev-helper.sh create my-excel-app
./scripts/excel-dev-helper.sh start my-excel-appπ See EXCEL_DEV_QUICKSTART.md for complete guide
One-click cloud development environment
-
Setup Gitpod (Windows 11 + WSL2):
git clone <repository-url> cd Devcontainers ./scripts/setup-gitpod-windows.sh
-
Open in Gitpod:
- Go to gitpod.io
- Open your repository
- Start coding immediately!
-
Start developing:
npm run dev-server
π Full Gitpod Guide: docs/gitpod-setup-guide.md
-
Clone or download this repository
git clone <repository-url> cd Devcontainers
-
Open the devcontainer using the helper script
./scripts/open-devcontainer.sh
-
Or build and open in one command
./scripts/open-devcontainer.sh --build
-
Clone or download this repository
git clone <repository-url> cd Devcontainers
-
Open in Cursor IDE with Dev Containers
- Open Cursor IDE
- Open the
DevContainerfolder - Cursor should prompt you to "Reopen in Container"
- Click "Reopen in Container"
-
Wait for the container to build
- The first build may take several minutes
- All dependencies will be automatically installed
-
Start developing
- Navigate to the
templatesdirectory - Choose a template and copy it to your project
- Run
npm installto install dependencies - Run
npm run dev-serverto start development
- Navigate to the
For advanced users, you can open the devcontainer directly via command-line:
# Using the helper script
./scripts/open-devcontainer.sh
# Or manually with Cursor CLI
CONF='{"settingType":"config", "workspacePath": ".", "devcontainerPath": "./DevContainer/devcontainer.json"}'
HEX_CONF=$(printf "$CONF" | od -A n -t x1 | tr -d '[\n\t ]')
cursor --folder-uri "vscode-remote://dev-container+${HEX_CONF}/workspaces"For detailed command-line usage, see the DevContainer Usage Guide.
A simple Excel Add-in that demonstrates basic Office.js functionality.
Features:
- Basic Office.js integration
- Cell manipulation
- Error handling
- TypeScript support
Usage:
cp -r templates/excel-addin-basic my-excel-addin
cd my-excel-addin
npm install
npm run dev-serverA tool for creating and inserting custom Excel functions.
Features:
- Custom function creation
- Formula validation
- Excel integration
- User-friendly interface
Usage:
cp -r templates/excel-function-builder my-function-builder
cd my-function-builder
npm install
npm run dev-serverA Tic-Tac-Toe game that runs inside Excel.
Features:
- Interactive game interface
- Excel integration
- Game state management
- Responsive design
Usage:
cp -r templates/excel-game my-excel-game
cd my-excel-game
npm install
npm run dev-server# Create new project
./scripts/excel-dev-helper.sh create my-project
# List all projects
./scripts/excel-dev-helper.sh list
# Start development server
./scripts/excel-dev-helper.sh start my-project
# Build project
./scripts/excel-dev-helper.sh build my-project
# Run tests
./scripts/excel-dev-helper.sh test my-project
# Show environment info
./scripts/excel-dev-helper.sh info
# Interactive menu
./scripts/excel-dev-helper.shnpm run build # Build for production
npm run build:dev # Build for development
npm run start # Start development server
npm run dev-server # Start development server with hot reloadnpm test # Run all tests
npm run test:watch # Run tests in watch mode
npm run test:coverage # Run tests with coverage report
npm run test:ui # Run Playwright UI testsnpm run lint # Run ESLint
npm run lint:fix # Fix ESLint issues
npm run format # Format code with Prettier
npm run validate # Validate Office Add-in manifestnpm run sideload # Sideload Add-in to Excel
npm run validate # Validate Add-in manifest
npm run dev-server # Start development server- Excel Dev Quick Start - β‘ Start here for fastest setup
- Excel Dev Helper Guide - Complete script documentation
- Getting Started Guide - Step-by-step setup and development
- DevContainer Usage Guide - Complete guide for using Dev Containers
- Troubleshooting Guide - Common issues and solutions
- GitIgnore Reference - Comprehensive guide to ignore rules and configuration
.gitignore- Comprehensive ignore rules for Node.js, TypeScript, and devcontainer projects.gitattributes- Line ending normalization for cross-platform development.dockerignore- Docker build optimization by excluding unnecessary files
- Office.js API Documentation
- Excel Add-in Development
- Office Add-in Samples
- Office Add-in Development Tools
-
Office.js not loading
- Ensure you're running in an Office environment
- Check that the manifest.xml is properly configured
- Verify the Office.js CDN is accessible
-
TypeScript errors
- Check your tsconfig.json configuration
- Ensure all dependencies are installed
- Verify Office.js types are properly imported
-
Build failures
- Verify all dependencies are installed with
npm install - Check for syntax errors in your code
- Ensure all required files are present
- Verify all dependencies are installed with
-
Container build issues
- Ensure Docker is running
- Check available disk space
- Try rebuilding the container
- Check the Office.js documentation
- Review the sample projects in the
templatesdirectory - Check the Office Add-in samples repository
- Review the troubleshooting guide in
docs/troubleshooting.md
To update the development environment:
-
Update the Dockerfile
- Modify the Dockerfile to include new dependencies
- Rebuild the container
-
Update VS Code extensions
- Modify the
extensionsarray indevcontainer.json - Rebuild the container
- Modify the
-
Update project templates
- Modify templates in the
templatesdirectory - Update documentation as needed
- Modify templates in the
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Update documentation
- Submit a pull request
MIT License - see LICENSE file for details
- Microsoft Office Add-ins team for Office.js
- VS Code team for Dev Containers
- TypeScript team for excellent tooling
- The open-source community for various tools and libraries
For support and questions:
- Create an issue in this repository
- Check the troubleshooting guide
- Review the Office.js documentation
- Join the Office Add-ins community
Happy coding with TypeScript and Excel! π