Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@
"author": "s0urce",
"license": "MIT",
"devDependencies": {
"wrangler": "2.0.5"
"wrangler": "3.0.0"
},
"private": true,
"scripts": {
"start": "wrangler dev",
"publish": "wrangler publish"
"publish": "wrangler deploy"
},
"dependencies": {
"@tsndr/cloudflare-worker-jwt": "^1.1.7",
"@tsndr/cloudflare-worker-jwt": "^2.2.1",
"cookie": "^0.5.0",
"dayjs": "^1.11.2",
"itty-router": "^2.6.1",
"js-cookie": "^3.0.1"
"dayjs": "^1.11.7",
"itty-router": "^3.0.12",
"js-cookie": "^3.0.5"
}
}
}
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { SECRET } from './constant'
const router = Router()

router.get('/', ({ url }) => {
const newHash = genRandomStr(3)
const newHash = genRandomStr(8)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, i choose 3 letter for easily memorize. 😂

// redirect to new page
return Response.redirect(`${url}${newHash}`, 302)
})
Expand Down