https://github.com/webmasterdevlin/elysiajs-demo
https://github.com/webmasterdevlin/elysiajs-demo
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/webmasterdevlin/elysiajs-demo
- Owner: webmasterdevlin
- Created: 2024-05-28T07:09:49.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-11-20T13:14:00.000Z (over 1 year ago)
- Last Synced: 2025-03-21T18:52:05.459Z (about 1 year ago)
- Language: JavaScript
- Size: 5.86 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Elysia with Bun runtime
## Getting Started
Install hyperfine for different OS
- https://github.com/sharkdp/hyperfine
To get started with this template, simply paste this command into your terminal:
```bash
bun create elysia ./elysia-example
```
## Development
To start the development server run:
```bash
bun run dev
```
Open http://localhost:3000/ with your browser to see the result.
### Update to latest npm
```bash
npm i -g npm@latest
```
### How to install bun globally
```bash
npm i -g bun@latest
```
### How to install pnpm globally
```bash
npm i -g @pnpm/exe@latest
```
### latest yarn inside a project
- see https://yarnpkg.com/migration/guide
- Yarn v4 is a bit complicated to set up because you need to enable corepack which removes pnpm from the global installed dependencies.
- You can install include yarn in the benchmarking test but it will the classic yarn and not the latest yarn v4.
- to learn more about corepack, go to this link. https://nodejs.org/api/corepack.html and https://yarnpkg.com/corepack
- You cana use latest pnpm and yarn without installing them using corepack.
```bash
corepack enable
```
```bash
yarn config set initScope myScope
yarn set version 4.5.1-dev
yarn install
```
### package manager benchmarking
```bash
hyperfine --prepare 'rm -rf node_modules' --warmup 1 --runs 1 'npm install' 'bun install' 'pnpm install' 'yarn install'
```