Ahead of I/O 2013, which starts later today, Google has announced a handful of useful enhancements to Apps Script.
Writing on the Google Apps Developer Blog,Saurabh Gupta outlines five areas of enhancement:
Scripts in Google Docs
In response for requests to be able to extend Google Docs in ways that are similar to Google Sheets, the App Script team has added custom menus, dialogs, and triggers. There's also a new custom sidebar feature plus a couple of secret features that will be announced during an I/O conference session.
The existing Forms Service can now be used to programmatically create and modify Google Forms and respond to form submissions.and there's a new 5-minute quickstart to help get started. You can also extend the Google Forms editor with the same custom menus, dialogs, and sidebars as Google Docs.
A new version of DocsList Service is available to automate Google Drive and Drive Service has been redesigned to make it easier to work with large numbers of files and to eliminate a lot of bugs. It has new features like setting the owner of a file or folder or changing the sharing settings.
Google I/O 2012 saw the launch of HtmlService for building custom user interfaces with secure client-side scripting. From today, there's an experimental version of a client-side sandbox for it that runs significantly faster in any browser that supports ECMAScript 5 strict mode.
Improved Authorization Flow and API Console Integration
Google developers have complained that authorizing a script takes too many steps. Now, you can opt in to an experimental new authorization flow that requires fewer clicks. In addition, every script that uses the new flow automatically creates a project in the Google APIs Console. This makes it much easier to use Google APIs that aren’t built in to Apps Script. To upgrade a script to the new flow, select File > Upgrade authorization experience.