Near Casino is a fake online casino that supports one game - coin flip. The website is mainly useful for developers serving as demo application using Appwrite and Sveite Kit.
Project focuses on multiple aspects:
Proof of server-side rendering kicking in properly with Appwrite and Svelte Kit (hosted on Vercel):
Near Casino uses multiple frontend and backend technologies with focus of simplifying the development. Main focus of tech stack in this project is to make development fast and fun, instead of making it scalable and micro-optimized.
Frontend:
npm install
npm run dev
Backend:
🚨 There is a bug in Vercel adapter! Please rename file from
_appwrite.json
toappwrite.json
after cloning this repository. 🚨
You only need to spin-up backend if you man on backend changes. For frontend changes, you can skip this step as project is connected to production backend instance.
nearCasino
appwrite login
appwrite deploy collection
appwrite deploy functions
, and configute environment variables in Appwite Web ConsoleTo prepare your changes from your Appwrite instance database to production one:
appwrite init collection
To create a new function:
appwrite init function
Feel free to do manual changes to appwrite.json if you are familiar with this file.
Frontend:
npm install
npm run build
build
on a static hostingFrontend build does not use any special environment variables.
Backend:
appwrite deploy collection
appwrite deploy function
Assets used in the project made by Alex Martynov.
Everything you need to build a Svelte project, powered by create-svelte
.
If you're seeing this, you've probably already done this step. Congrats!!!
# create a new project in the current directory
npm init svelte
# create a new project in my-app
npm init svelte my-app
Once you've created a project and installed dependencies with npm install
(or pnpm install
or yarn
), start a development server:
npm run dev
# or start the server and open the app in a new browser tab
npm run dev -- --open
To create a production version of your app:
npm run build
You can preview the production build with npm run preview
.
To deploy your app, you may need to install an adapter for your target environment.