Using Sheetbase to build a website/app.
You can use Sheetbase platform to build a REST API only (see below) or a fully functional app.
Install the Sheetbase CLI, it is the main tool for developing project. Make sure you have Node and npm installed, see Evironment setup for more.
npm install -g @sheetbase/cli@latest
Enable Apps Script API, go to https://script.google.com/home/usersettings, then enable the API.
Add and manage Google Apps Script from your Google Drive:
My Drive (click dropdown) > More > Connect more apps > (search for Google Apps Script) > Connect
Run this command to create a new app, replace
project_name with your app name (remember to double quote if the name contains space).
sheetbase start <project_name>
sheetbase start myapp or
sheetbase start "My Awesome Website"
Or manually, clone a theme from the themes list: https://sheetbase.dev/themes
The CLI skip installing npm dependencies (
npm install), you need to install them before start developing.
Install backend dependencies:
cd backend && npm install
Install frontend dependencies:
cd frontend && npm install
If you wish the CLI to install dependencies for you, add
-i (–install) flag with
sheetbase start myapp -i.
The Sheetbase CLI provides convenient commands for easily build and deploy a Sheetbase project.
For an app, backend code lives in backend/ folder.
sheetbase backend test(npm run test)
sheetbase backend build(npm run build)
sheetbase backend push(update code in the Apps Script server, without redeploy the webapp)
sheetbase backend deploy(push code, save new version and redeploy the webapp)
For an app, frontend code lives in frontend/ folder.
sheetbase frontend test(npm run test)
sheetbase frontend e2e(npm run e2e)
sheetbase frontend build(npm run build)
sheetbase frontend prerender(prerender content, save sitemap.xml & robots.txt)
sheetbase frontend deploy(redeploy to a static server)
If you only wish to build a REST API server, then clone the blank backend app from: https://github.com/sheetbase/blank-server-app
It just like buidling a full app, but without the frontend part.
Before starting develop the backend and frontend code. You may want to edit these files to customise your project.
sheetbase.json(DO NOT change auto generated values, and remember to run
sheetbase config updateafter changing the file)
frontend/src/app/app.config.ts(project may have separated frontend configs)
frontend/src/theme/variables.scssand Sheetbase theming
You want also want to build and deploy the backend for Review permissions, see Publishing backend for more.