Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
goel4ever committed Jun 5, 2024
1 parent 85f96fd commit 89f9ceb
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 1 deletion.
7 changes: 7 additions & 0 deletions src/Local/git-cli/cheatsheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ $ git diff --cached
# Create new commit that undoes all of the changes made in <commit>, then apply
$ git revert <commit>

# Discard changes in working directory or the staging area
$ git restore <file>
# Restore myfile.txt in staging area and working directory to the state of last commit (HEAD)
$ git restore --source=HEAD --staged --worktree myfile.txt

# Reset staging area to match most recent commit, but leave code unchanged
$ git reset
# Remove <file> from staging area
Expand All @@ -55,6 +60,8 @@ $ git reset --hard
$ git reset <commit>
# Move current branch tip backward to <commit>, reset staging area as well as local code
$ git reset --hard <commit>
# Move HEAD (and the branch pointer) one commit back, discarding the last commit and all changes in the staging area and the working directory
$ git reset --hard HEAD~1

# Remove untracked files from your working directory
$ git clean
Expand Down
39 changes: 38 additions & 1 deletion src/why-nots/static-site-generator.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,42 @@
# Static Site Generator

## Deployment

- Netlify
- Vercel
- Cloudflare
- [fly.io](https://fly.io/)

## Top comments from blogs

### Cloudflare

Cloudflare is a lot more generous with bandwidth. It's basically unmetered.
Cloudflare Pages also provide preview deployments and you can handle server-side logic and SSR with Cloudflare Workers.

Cloudflare provides most what Vercel does through Pages and Workers, and additionally they also provide storage (KV database, object storage and blob storage), email routing and other services – as long as you're ok to be locked in with their services.

If you are looking for a platform that offers unlimited builds and deploys of static websites and serverless functions, Cloudflare Pages may be the better option

### Vercel

Vercel's free plan is limited to 100gb or so, and gets really expensive if you are using more than 1tb a month. Bandwidth is basically data transfer. vercel (and most other web hosts) will meter how much data your site is using and charge you for it

Vercel does have the best support nextjs's SSR features, compared to cloudflare which only supports ssr on nextjs version 12.

Vercel has a convenient feature where it will auto-deploy your feature branches and post a preview link on github, so it's great if you are working on a team and you want to QA other peoples work before merging.

Vercel is a great choice for Next.js, but their server-side hosting is limited to "serverless" functions. They also don't provide much extra services outside of core hosting, for example you'll have to pick some other hosting for a database or files storage.

Vercel isn’t allowing commercial use while Cloudflare does, with the free plan.

### Fly.io

Fly is the closest one to Heroku, it lets you run a “traditional” stateful server (e.g. Express) and a database in a free tier, so it's nice choice if you want to use for example MERN stack.

## References

- [docsify](https://github.com/docsifyjs/docsify)
- Generators
- [docsify](https://github.com/docsifyjs/docsify)
- Deployment services
- [Cloudflare vs Vercel vs FLY io, where to deploy?](https://www.reddit.com/r/react/comments/10gc644/cloudflare_vs_vercel_vs_fly_io_where_to_deploy/) | Stackoverflow

0 comments on commit 89f9ceb

Please sign in to comment.