Clone the repository
git clone https://github.com/onehassan/nhost-sveltekit-example
cd nhost-sveltekit-example
Install dependencies
npm install
Create a .env file and fill in with your nhost project's region
and subdomain
.
PUBLIC_NHOST_REGION=
PUBLIC_NHOST_SUBDOMAIN=
Start the development server
npm run dev
Create new nhost project using the CLI
Make sure you have the Nhost CLI installed.
nhost init
set the PUBLIC_NHOST_SUBDOMAIN
to local
in the .env
file
PUBLIC_NHOST_SUBDOMAIN=local
Terminal 1: Start Nhost
nhost up
Terminal 2: Start the SvelteKit dev server
npm run dev