elysiajs / elysia-static

Plugin for Elysia for serving static folder
MIT License
12 stars 17 forks source link

Installing `@elysiajs/static` downgrades `raikiri` #4

Closed bogeychan closed 1 year ago

bogeychan commented 1 year ago

Raikiri was listed as a dependency:

https://github.com/elysiajs/elysia-static/blob/2c330cce74aadc6994b669f00a76bbbbc491e888/package.json#L48

I removed it.

It was not used and caused a version downgrade as a side effect when installing the plugin in an Elysia.js project with Bun or Yarn, as the following commands show:

With Bun v0.5.9 (or Yarn v1.22.19)

mkdir tmp-app && \
cd tmp-app && \
bun create elysia . && \
head -3 node_modules/raikiri/package.json && \
bun add @elysiajs/static && \
head -3 node_modules/raikiri/package.json

OR

mkdir tmp-app && \
cd tmp-app && \
bun init -y && \
bun add elysia && \
head -3 node_modules/raikiri/package.json && \
bun add @elysiajs/static && \
head -3 node_modules/raikiri/package.json

Causes

node_modules/raikiri/package.json

  "name": "raikiri",
-   "version": "0.1.3",
+   "version": "0.1.0-beta.1",

Same command under NPM v9.5.1 (or PNPM v8.3.1)

mkdir tmp-app && \
cd tmp-app && \
npm init -y && \
npm i elysia && \
head -3 node_modules/raikiri/package.json && \
npm i @elysiajs/static && \
head -3 node_modules/raikiri/package.json

"Works"

node_modules/raikiri/package.json

  "name": "raikiri",
+  "version": "0.1.3",