Skip to content

Template with a SPA and netlify functions as backend, both with typescript

License

Notifications You must be signed in to change notification settings

casrpg/spa-netlify-ts-monorepo

Repository files navigation

SPA + Netlify functions monorepo template with Typescript

This is a simple template for a monorepo containing an SPA built with Vite and with Netlify functions both using Typescript.

It uses npm workspaces so you can have different dependencies for the frontend and the backend.

Install

Run npm install

Run the app

Run npm start

Test the app

You can run the tests with npm test.

To run the e2e test, you need to install playwright first and then run npm test:e2e.

Troubleshooting

Vscode fails to run the linter

Put this into the .vscode/settings.json file:

{
  "eslint.workingDirectories": [
    "app",
    "functions",
  ]
}