OfficeDev / script-lab

Create, run and share your code directly from Office
MIT License
709 stars 163 forks source link
code-editor office-addin script-lab typescript

Script Lab, a Microsoft Garage project

Experiment with the Office JavaScript API without leaving Excel, Outlook, Word, or PowerPoint!

Get Script Lab in Excel, Word, and PowerPoint, or Script Lab for Outlook, free from Microsoft AppSource.

Read the blog post on the future of Script Lab.

Topics

What is Script Lab?

Wouldn't it be crazy if you could launch Excel, click to open a small code window, and then instantly start writing and executing JavaScript that interacts with your spreadsheet?

Script lab is a tool for anyone who wants to learn about writing Office Add-ins for Excel, Outlook, Word, or PowerPoint. The focus is the Office JavaScript API, which is the technology you need for building Office Add-ins that run across platforms. Maybe you're an experienced Office developer and you want to quickly prototype a feature for your add-in. Or maybe you've never tried writing code for Office and you just want to play with a sample and tweak it to learn more. Either way, Script Lab is for you.

Script Lab has three main features:

Script Lab works in Office 2013 or later on Windows, Office on the web, or Office on Mac.

You can get Script Lab right now for free from Microsoft AppSource! It works for Excel, Word, and PowerPoint.

If you're interested in developing for Outlook, you can get Script Lab for Outlook, also free from AppSource.

Script Lab is a Microsoft Garage project that began at a hackathon. You can read the story of the original Script Lab creation on the Garage website.

Here's a 1-minute teaser video:

Script Lab teaser video showing Script Lab being used in Excel to make charts, Word, and Powerpoint Online.

Get Started

Explore Office JavaScript API using Script Lab

This 10-minute demo explains how to use the main features:

Michael Saunders demos Script Lab

Import someone else's snippet, or export your own

Script Lab is built around sharing. If someone gives you a URL to a GitHub Gist, simply open Script Lab, use the hamburger menu at the top left to see the menu, and choose "Import" category (either on the left or top, depending on the available screen space). Then, enter the URL of the Gist, and click the "Import" button at the bottom of the screen. In just these few clicks, you will be able to view and run someone else's snippet!

Import tab within the "Hamburger" menu showing a text box to import a URL, GitHub gist ID, or snippet YAML

Conversely, to share your snippet with someone, choose the "Copy to clipboard" button with the open snippet. You can share as a public GitHub Gist, or you can paste the snippet from the clipboard, and share it from there.

Report a bug, or suggest a feature

To report a bug, create a new issue. Please provide as much detail as you can, tell us: the operating system, the Office build number, and your browser (if you're using Office on the web).

If you have a suggestion for a feature, please feel free to file it under "issues" as well, and we will tag it appropriately. The more detail, the better! (see more at CONTRIBUTING.md).

If you have a question, please ask it on Stack Overflow and tag your questions with office-js and scriptlab.

Stay up-to-date

Contribute to Script Lab

There are a bunch of ways you can contribute to Script Lab:

Rate and review

Leave a star-rating and (optionally) a review blurb for Script Lab on the Office Store review page.

We'd prefer you report issues on GitHub.

Articles & FAQs

External media coverage

Code of conduct

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.