Commit Graph

25 Commits

Author SHA1 Message Date
Elisha Nuchi 248a90023c Feature: Support closing dialog windows (#233)
Supports closing dialogs in development. Upgrades gas-client to 1.2.0 and uses new API here: Add scriptHostFunctions for google.script.host gas-client#36
Example button to close dialog in Bootstrap sample
Updates integration tests
2025-03-16 12:13:30 -04:00
Elisha Nuchi a976451c78 Update README.md
- Add videos to README.md
2024-05-20 00:32:28 -04:00
Elisha Nuchi 31befe1d68 V3: Migrate to Vite (#221)
This is version 3 of the boilerplate, which makes significant changes to the build script and local development tooling. It replaces Webpack with Vite, which required some significant changes to how the local development setup works with Google Apps Script.

A new dev-server-wrapper.html file is used as the wrapper app in development, which is a standalone html + js file instead of a React app. This reduces the need for a complex build step for the wrapper app. Instead the file is just copied over for each entrypoing and the file location is changed with a "replace" step.

Due to the way Vite works, the html templates are changed a bit to support local development.

Vite doesn't easily allow completely separate multiple builds, so some Vite plugins and custom plugins are written to support multiple entrypoints (sidebars/dialogs). The externalization for large packages is now handled in the Vite config instead of a plugin, and by manually adding in the script tags into the index.html templates.

Additional changes here:
- yarn is now used instead of npm as package manager
- eslint configs are updated to support vite
- GitHub workflows for tests are updated to use yarn and other minor changes such as node versions and OS.
- A VS Code launch.json configuration is provided
- Dev wrapper setup has been updated (see above description)
- ES Modules (import/export) updated throughout
- Unneeded packages supporting webpack configurations are removed. Many packages have been upgraded. NPM scripts have been updated to use yarn.
- Removed `import React` due to Vite config.
- Added script tags to each template since webpack externalization plugin is no longer used
- Added <script type="module" src="./index.jsx"></script> to index.html templates to support Vite local development
- Changed src/server/sheets.js to .ts typescript as exemplar
- Updated tests to support yarn commands, Vite changes, and listening for Vite stdout triggers.
- Add Vite-style tsconfig.json
- README is updated
2024-05-20 00:25:31 -04:00
Elisha Nuchi 5f2012ce56 Update integration tests and package versions (#211)
* Update gas-types-detailed package

* Update LICENSE

* update node versions and macos versions in workflows

* add NODE_OPTIONS env: max_old_space_size=4096

* support new log-in flow
2024-03-22 01:40:15 -04:00
Elisha Nuchi 8265933d4b Update README.md (#180)
Clean up outdated descriptions and add more info in some areas.
2023-03-10 23:54:05 -05:00
Elisha Nuchi a323926739 Update setup script (#137)
Handles changes in @google/clasp@2.4.1 affecting rooDir flag
2022-08-12 23:19:12 -04:00
Elisha Nuchi fd73dc051c Webpack 5 support with updated packages (#131)
- Update to Webpack 5
- Use @effortlessmotion dynamic html and inline source plugins
- Remove .clasp.json and use SAMPLE file
- Consistent prettier formatting throughout
- Update packages to latest versions

Co-authored-by: Kevin Malakoff <kmalakoff@gmail.com>
2022-06-20 01:59:26 -04:00
Elisha Nuchi 531a952df3 Support react-refresh and shared client/server types (#98)
- Adds support for react-refresh through `@pmmwh/react-refresh-webpack-plugin`. Updated webpack config to support this. Means entire app is no longer refreshed on changes, only individual components, and state is maintained.
- React refresh removes need for `google-apps-script-webpack-dev-server` package
- In client code, support for server function autocomplete through use of gas-client 1.0.0. Requires certain files to be typescript .ts files
- Remove need for "global" exports in main server file through updated gas-webpack-plugin
2022-03-14 12:31:52 -04:00
Elisha Nuchi f8a471c93d Feature/update clasp (#106)
* update to @google/clasp@2.4.0

- Add npm run open command
- Update readme to explain how to add existing script and document which works with npm run open
- Remove npm run setup:use-id command
2021-07-19 14:14:30 -04:00
Elisha Nuchi 2b8f0dc9d4 Docs/React DevTools documentation (#80)
Add documentation on using React DevTools
2021-04-24 00:55:27 -04:00
Juan Ignacio Telechea 18fb03d42c docs: webpack config line updated (#77) 2021-03-18 22:48:23 -04:00
Elisha Nuchi 886ec2e72a Update README.md
Update acknowledgements
2020-08-16 22:35:16 -04:00
Elisha Nuchi 35a641d0f7 v2 Enable local development (#52)
- Create local dev environment
- Add gas-client and google-apps-script-webpack-dev-server packages for development
- Add dev/ wrapper app
- Update webpack config to support development environment
- Redesigned READMEs
- Support typescript
- Update npm scripts
- Organize and update .gitignore file
- Add .vscode settings for clasp files
- Remove tracking for files in dist/
2020-08-15 13:09:04 -04:00
Agustin Burset b346f4fede Fix server magic implementation link 2020-07-27 10:14:27 -03:00
Elisha Nuchi f2a259ce66 add Bootstrap working example
• re-organize file structure with one directory per dialog
• add index.html file per dialog
• add bootstrap styling and dynamic cdn loading
• clean up react code and stylesheet

npm setup script update

adds force flag
"setup": "rm -f .clasp.json ..."

Update README.md

Move clasp to devDependencies

update dynamic cdn urls

Add repository field
2020-07-12 20:18:40 -04:00
Elisha Nuchi 4385be0f6b fix readme issues 2020-05-04 03:31:47 -04:00
Elisha Nuchi 381e2c95ae Update README.md 2020-05-04 03:21:08 -04:00
Elisha Nuchi 0ea874e8b4 update webpack, update packages, dev experience
update webpack, clasp, client code, eslint, prettier, readme, packages to latest
2020-05-03 05:12:50 -04:00
Elisha Nuchi 7f5e236e6a update readme
new installation instructions, explain more features such as multiple entrypoints and google.script.run 'server'
2019-07-16 23:44:47 -04:00
Yoni Slotwinere 118af27cc0 updated readme; upgraded @google/clasp to v1.5.3 2018-09-18 16:50:36 -04:00
Elisha Nuchi 7783b36193 more options 2018-09-17 15:46:54 -04:00
Elisha Nuchi ff3f14a4f1 more settings enabled 2018-09-17 03:18:15 -04:00
Elisha Nuchi 3e2d186956 add warning 2018-09-13 00:58:11 -04:00
Elisha Nuchi 0dc06b79b8 first commit 2018-09-12 21:13:21 -04:00
Elisha Nuchi 0118a94549 first commit 2018-09-12 21:12:35 -04:00