From 6f79398625868a63e81dc012244c5aa8ae384c16 Mon Sep 17 00:00:00 2001 From: Matteo Merz Date: Thu, 14 Sep 2023 09:37:15 +0200 Subject: [PATCH 1/8] Added Worker for creating JWT for react frontend challenge --- docs/pages/challenges/micro/frontend/react/jwt-auth | 1 + 1 file changed, 1 insertion(+) create mode 160000 docs/pages/challenges/micro/frontend/react/jwt-auth diff --git a/docs/pages/challenges/micro/frontend/react/jwt-auth b/docs/pages/challenges/micro/frontend/react/jwt-auth new file mode 160000 index 0000000..b7d1f1d --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react/jwt-auth @@ -0,0 +1 @@ +Subproject commit b7d1f1d275c764a0cfe73f51632de0d61710d173 From ad8f0eabd4c8bc0327950632b0fb481210509c06 Mon Sep 17 00:00:00 2001 From: Matteo Merz Date: Thu, 14 Sep 2023 09:51:52 +0200 Subject: [PATCH 2/8] Added JWT authorizer for react2 challenge --- .../challenges/micro/frontend/react/jwt-auth | 1 - .../react2/jwt-authorizer/.editorconfig | 13 + .../react2/jwt-authorizer/.prettierrc | 6 + .../react2/jwt-authorizer/package-lock.json | 1687 +++++++++++++++++ .../react2/jwt-authorizer/package.json | 17 + .../react2/jwt-authorizer/src/index.ts | 23 + .../react2/jwt-authorizer/tsconfig.json | 101 + .../react2/jwt-authorizer/wrangler.toml | 51 + 8 files changed, 1898 insertions(+), 1 deletion(-) delete mode 160000 docs/pages/challenges/micro/frontend/react/jwt-auth create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.editorconfig create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.prettierrc create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package-lock.json create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package.json create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/src/index.ts create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/tsconfig.json create mode 100644 docs/pages/challenges/micro/frontend/react2/jwt-authorizer/wrangler.toml diff --git a/docs/pages/challenges/micro/frontend/react/jwt-auth b/docs/pages/challenges/micro/frontend/react/jwt-auth deleted file mode 160000 index b7d1f1d..0000000 --- a/docs/pages/challenges/micro/frontend/react/jwt-auth +++ /dev/null @@ -1 +0,0 @@ -Subproject commit b7d1f1d275c764a0cfe73f51632de0d61710d173 diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.editorconfig b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.editorconfig new file mode 100644 index 0000000..64ab260 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.editorconfig @@ -0,0 +1,13 @@ +# http://editorconfig.org +root = true + +[*] +indent_style = tab +tab_width = 2 +end_of_line = lf +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[*.yml] +indent_style = space diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.prettierrc b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.prettierrc new file mode 100644 index 0000000..5c7b5d3 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/.prettierrc @@ -0,0 +1,6 @@ +{ + "printWidth": 140, + "singleQuote": true, + "semi": true, + "useTabs": true +} diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package-lock.json b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package-lock.json new file mode 100644 index 0000000..0de7006 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package-lock.json @@ -0,0 +1,1687 @@ +{ + "name": "jwt-authorizer", + "version": "0.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "jwt-authorizer", + "version": "0.0.0", + "dependencies": { + "@tsndr/cloudflare-worker-jwt": "^2.2.2" + }, + "devDependencies": { + "@cloudflare/workers-types": "^4.20230419.0", + "typescript": "^5.0.4", + "wrangler": "^3.0.0" + } + }, + "node_modules/@cloudflare/kv-asset-handler": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@cloudflare/kv-asset-handler/-/kv-asset-handler-0.2.0.tgz", + "integrity": "sha512-MVbXLbTcAotOPUj0pAMhVtJ+3/kFkwJqc5qNOleOZTv6QkZZABDMS21dSrSlVswEHwrpWC03e4fWytjqKvuE2A==", + "dev": true, + "dependencies": { + "mime": "^3.0.0" + } + }, + "node_modules/@cloudflare/workerd-darwin-64": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workerd-darwin-64/-/workerd-darwin-64-1.20230904.0.tgz", + "integrity": "sha512-/GDlmxAFbDtrQwP4zOXFbqOfaPvkDxdsCoEa+KEBcAl5uR98+7WW5/b8naBHX+t26uS7p4bLlImM8J5F1ienRQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=16" + } + }, + "node_modules/@cloudflare/workerd-darwin-arm64": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workerd-darwin-arm64/-/workerd-darwin-arm64-1.20230904.0.tgz", + "integrity": "sha512-x8WXNc2xnDqr5y1iirnNdyx8GZY3rL5xiF7ebK3mKQeB+jFjkhO71yuPTkDCzUWtOvw1Wfd4jbwy4wxacMX4mQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=16" + } + }, + "node_modules/@cloudflare/workerd-linux-64": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workerd-linux-64/-/workerd-linux-64-1.20230904.0.tgz", + "integrity": "sha512-V58xyMS3oDpKO8Dpdh0r0BXm99OzoGgvWe9ufttVraj/1NTMGELwb6i9ySb8k3F1J9m/sO26+TV7pQc/bGC1VQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16" + } + }, + "node_modules/@cloudflare/workerd-linux-arm64": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workerd-linux-arm64/-/workerd-linux-arm64-1.20230904.0.tgz", + "integrity": "sha512-VrDaW+pjb5IAKEnNWtEaFiG377kXKmk5Fu0Era4W+jKzPON2BW/qRb/4LNHXQ4yxg/2HLm7RiUTn7JZtt1qO6A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16" + } + }, + "node_modules/@cloudflare/workerd-windows-64": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workerd-windows-64/-/workerd-windows-64-1.20230904.0.tgz", + "integrity": "sha512-/R/dE8uy+8J2YeXfDhI8/Bg7YUirdbbjH5/l/Vv00ZRE0lC3nPLcYeyBXSwXIQ6/Xht3gN+lksLQgKd0ZWRd+Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=16" + } + }, + "node_modules/@cloudflare/workers-types": { + "version": "4.20230904.0", + "resolved": "https://registry.npmjs.org/@cloudflare/workers-types/-/workers-types-4.20230904.0.tgz", + "integrity": "sha512-IX4oJCe14ctblSPZBlW64BVZ9nYLUo6sD2I5gu3hX0ywByYWm1OuoKm9Xb/Zpbj8Ph18Z7Ryii6u2/ocnncXdA==", + "dev": true + }, + "node_modules/@esbuild-plugins/node-globals-polyfill": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@esbuild-plugins/node-globals-polyfill/-/node-globals-polyfill-0.2.3.tgz", + "integrity": "sha512-r3MIryXDeXDOZh7ih1l/yE9ZLORCd5e8vWg02azWRGj5SPTuoh69A2AIyn0Z31V/kHBfZ4HgWJ+OK3GTTwLmnw==", + "dev": true, + "peerDependencies": { + "esbuild": "*" + } + }, + "node_modules/@esbuild-plugins/node-modules-polyfill": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/@esbuild-plugins/node-modules-polyfill/-/node-modules-polyfill-0.2.2.tgz", + "integrity": "sha512-LXV7QsWJxRuMYvKbiznh+U1ilIop3g2TeKRzUxOG5X3YITc8JyyTa90BmLwqqv0YnX4v32CSlG+vsziZp9dMvA==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^4.0.0", + "rollup-plugin-node-polyfills": "^0.2.1" + }, + "peerDependencies": { + "esbuild": "*" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.17.19.tgz", + "integrity": "sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.17.19.tgz", + "integrity": "sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.17.19.tgz", + "integrity": "sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.17.19.tgz", + "integrity": "sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.17.19.tgz", + "integrity": "sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.17.19.tgz", + "integrity": "sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.17.19.tgz", + "integrity": "sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.17.19.tgz", + "integrity": "sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.17.19.tgz", + "integrity": "sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.17.19.tgz", + "integrity": "sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.17.19.tgz", + "integrity": "sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.17.19.tgz", + "integrity": "sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.17.19.tgz", + "integrity": "sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.17.19.tgz", + "integrity": "sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.17.19.tgz", + "integrity": "sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.17.19.tgz", + "integrity": "sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.17.19.tgz", + "integrity": "sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.17.19.tgz", + "integrity": "sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.17.19.tgz", + "integrity": "sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.17.19.tgz", + "integrity": "sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.17.19.tgz", + "integrity": "sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.17.19.tgz", + "integrity": "sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@tsndr/cloudflare-worker-jwt": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/@tsndr/cloudflare-worker-jwt/-/cloudflare-worker-jwt-2.2.2.tgz", + "integrity": "sha512-l+UFCSrJYwFQpszz4hHKYi5q8EI+r00LEi9UgQtf7+7/RlRg59kE5m4gjHkWRANDDAAhAd6DsnwanlABI8LJzQ==" + }, + "node_modules/acorn": { + "version": "8.10.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz", + "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==", + "dev": true, + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/acorn-walk": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", + "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "dev": true, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/as-table": { + "version": "1.0.55", + "resolved": "https://registry.npmjs.org/as-table/-/as-table-1.0.55.tgz", + "integrity": "sha512-xvsWESUJn0JN421Xb9MQw6AsMHRCUknCe0Wjlxvjud80mU4E6hQf1A6NzQKcYNmYw62MfzEtXc+badstZP3JpQ==", + "dev": true, + "dependencies": { + "printable-characters": "^1.0.42" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/better-sqlite3": { + "version": "8.6.0", + "resolved": "https://registry.npmjs.org/better-sqlite3/-/better-sqlite3-8.6.0.tgz", + "integrity": "sha512-jwAudeiTMTSyby+/SfbHDebShbmC2MCH8mU2+DXi0WJfv13ypEJm47cd3kljmy/H130CazEvkf2Li//ewcMJ1g==", + "dev": true, + "hasInstallScript": true, + "dependencies": { + "bindings": "^1.5.0", + "prebuild-install": "^7.1.1" + } + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "dev": true, + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "dev": true, + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "node_modules/blake3-wasm": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/blake3-wasm/-/blake3-wasm-2.1.5.tgz", + "integrity": "sha512-F1+K8EbfOZE49dtoPtmxUQrpXaBIl3ICvasLh+nJta0xkz+9kF/7uet9fLnwKqhDrmj6g+6K3Tw9yQPUg2ka5g==", + "dev": true + }, + "node_modules/braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", + "dev": true + }, + "node_modules/busboy": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/busboy/-/busboy-1.6.0.tgz", + "integrity": "sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==", + "dev": true, + "dependencies": { + "streamsearch": "^1.1.0" + }, + "engines": { + "node": ">=10.16.0" + } + }, + "node_modules/capnp-ts": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/capnp-ts/-/capnp-ts-0.7.0.tgz", + "integrity": "sha512-XKxXAC3HVPv7r674zP0VC3RTXz+/JKhfyw94ljvF80yynK6VkTnqE3jMuN8b3dUVmmc43TjyxjW4KTsmB3c86g==", + "dev": true, + "dependencies": { + "debug": "^4.3.1", + "tslib": "^2.2.0" + } + }, + "node_modules/chokidar": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + ], + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/chownr": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", + "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", + "dev": true + }, + "node_modules/cookie": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz", + "integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==", + "dev": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/data-uri-to-buffer": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-2.0.2.tgz", + "integrity": "sha512-ND9qDTLc6diwj+Xe5cdAgVTbLVdXbtxTJRXRhli8Mowuaan+0EJOtdqJ0QCHNSSPyoXGx9HX2/VMnKeC34AChA==", + "dev": true + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "dev": true, + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "dev": true, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/detect-libc": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz", + "integrity": "sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dev": true, + "dependencies": { + "once": "^1.4.0" + } + }, + "node_modules/esbuild": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.17.19.tgz", + "integrity": "sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/android-arm": "0.17.19", + "@esbuild/android-arm64": "0.17.19", + "@esbuild/android-x64": "0.17.19", + "@esbuild/darwin-arm64": "0.17.19", + "@esbuild/darwin-x64": "0.17.19", + "@esbuild/freebsd-arm64": "0.17.19", + "@esbuild/freebsd-x64": "0.17.19", + "@esbuild/linux-arm": "0.17.19", + "@esbuild/linux-arm64": "0.17.19", + "@esbuild/linux-ia32": "0.17.19", + "@esbuild/linux-loong64": "0.17.19", + "@esbuild/linux-mips64el": "0.17.19", + "@esbuild/linux-ppc64": "0.17.19", + "@esbuild/linux-riscv64": "0.17.19", + "@esbuild/linux-s390x": "0.17.19", + "@esbuild/linux-x64": "0.17.19", + "@esbuild/netbsd-x64": "0.17.19", + "@esbuild/openbsd-x64": "0.17.19", + "@esbuild/sunos-x64": "0.17.19", + "@esbuild/win32-arm64": "0.17.19", + "@esbuild/win32-ia32": "0.17.19", + "@esbuild/win32-x64": "0.17.19" + } + }, + "node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/estree-walker": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-0.6.1.tgz", + "integrity": "sha512-SqmZANLWS0mnatqbSfRP5g8OXZC12Fgg1IwNtLsyHDzJizORW4khDfjPqJZsemPWBB2uqykUah5YpQ6epsqC/w==", + "dev": true + }, + "node_modules/exit-hook": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/exit-hook/-/exit-hook-2.2.1.tgz", + "integrity": "sha512-eNTPlAD67BmP31LDINZ3U7HSF8l57TxOY2PmBJ1shpCvpnxBF93mWCE8YHBnXs8qiUZJc9WDcWIeC3a2HIAMfw==", + "dev": true, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "dev": true + }, + "node_modules/fill-range": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", + "dev": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/get-source": { + "version": "2.0.12", + "resolved": "https://registry.npmjs.org/get-source/-/get-source-2.0.12.tgz", + "integrity": "sha512-X5+4+iD+HoSeEED+uwrQ07BOQr0kEDFMVqqpBuI+RaZBpBpHCuXxo70bjar6f0b0u/DQJsJ7ssurpP0V60Az+w==", + "dev": true, + "dependencies": { + "data-uri-to-buffer": "^2.0.0", + "source-map": "^0.6.1" + } + }, + "node_modules/get-source/node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/github-from-package": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", + "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", + "dev": true + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/glob-to-regexp": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", + "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", + "dev": true + }, + "node_modules/http-cache-semantics": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", + "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", + "dev": true + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true + }, + "node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "dev": true + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/kleur": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", + "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/magic-string": { + "version": "0.25.9", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.9.tgz", + "integrity": "sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==", + "dev": true, + "dependencies": { + "sourcemap-codec": "^1.4.8" + } + }, + "node_modules/mime": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-3.0.0.tgz", + "integrity": "sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A==", + "dev": true, + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/miniflare": { + "version": "3.20230904.0", + "resolved": "https://registry.npmjs.org/miniflare/-/miniflare-3.20230904.0.tgz", + "integrity": "sha512-+OWQqEk8hV7vZaPCoj5dk1lZr4YUy56OiyNZ45/3ITYf+ZxgQOBPWhQhpw1jCahkRKGPa9Aykz01sc+GhPZYDA==", + "dev": true, + "dependencies": { + "acorn": "^8.8.0", + "acorn-walk": "^8.2.0", + "better-sqlite3": "^8.1.0", + "capnp-ts": "^0.7.0", + "exit-hook": "^2.2.1", + "glob-to-regexp": "^0.4.1", + "http-cache-semantics": "^4.1.0", + "kleur": "^4.1.5", + "source-map-support": "0.5.21", + "stoppable": "^1.1.0", + "undici": "^5.22.1", + "workerd": "1.20230904.0", + "ws": "^8.11.0", + "youch": "^3.2.2", + "zod": "^3.20.6" + }, + "engines": { + "node": ">=16.13" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/mkdirp-classic": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", + "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", + "dev": true + }, + "node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/mustache": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/mustache/-/mustache-4.2.0.tgz", + "integrity": "sha512-71ippSywq5Yb7/tVYyGbkBggbU8H3u5Rz56fH60jGFgr8uHwxs+aSKeqmluIVzM0m0kB7xQjKS6qPfd0b2ZoqQ==", + "dev": true, + "bin": { + "mustache": "bin/mustache" + } + }, + "node_modules/nanoid": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.6.tgz", + "integrity": "sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/napi-build-utils": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-1.0.2.tgz", + "integrity": "sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==", + "dev": true + }, + "node_modules/node-abi": { + "version": "3.47.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.47.0.tgz", + "integrity": "sha512-2s6B2CWZM//kPgwnuI0KrYwNjfdByE25zvAaEpq9IH4zcNsarH8Ihu/UuX6XMPEogDAxkuUFeZn60pXNHAqn3A==", + "dev": true, + "dependencies": { + "semver": "^7.3.5" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-forge": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-1.3.1.tgz", + "integrity": "sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==", + "dev": true, + "engines": { + "node": ">= 6.13.0" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/path-to-regexp": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-6.2.1.tgz", + "integrity": "sha512-JLyh7xT1kizaEvcaXOQwOc2/Yhw6KZOvPf1S8401UyLk86CU79LN3vl7ztXGm/pZ+YjoyAJ4rxmHwbkBXJX+yw==", + "dev": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/prebuild-install": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.1.tgz", + "integrity": "sha512-jAXscXWMcCK8GgCoHOfIr0ODh5ai8mj63L2nWrjuAgXE6tDyYGnx4/8o/rCgU+B4JSyZBKbeZqzhtwtC3ovxjw==", + "dev": true, + "dependencies": { + "detect-libc": "^2.0.0", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.3", + "mkdirp-classic": "^0.5.3", + "napi-build-utils": "^1.0.1", + "node-abi": "^3.3.0", + "pump": "^3.0.0", + "rc": "^1.2.7", + "simple-get": "^4.0.0", + "tar-fs": "^2.0.0", + "tunnel-agent": "^0.6.0" + }, + "bin": { + "prebuild-install": "bin.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/printable-characters": { + "version": "1.0.42", + "resolved": "https://registry.npmjs.org/printable-characters/-/printable-characters-1.0.42.tgz", + "integrity": "sha512-dKp+C4iXWK4vVYZmYSd0KBH5F/h1HoZRsbJ82AVKRO3PEo8L4lBS/vLwhVtpwwuYcoIsVY+1JYKR268yn480uQ==", + "dev": true + }, + "node_modules/pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dev": true, + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "dev": true, + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dev": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/rollup-plugin-inject": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/rollup-plugin-inject/-/rollup-plugin-inject-3.0.2.tgz", + "integrity": "sha512-ptg9PQwzs3orn4jkgXJ74bfs5vYz1NCZlSQMBUA0wKcGp5i5pA1AO3fOUEte8enhGUC+iapTCzEWw2jEFFUO/w==", + "deprecated": "This package has been deprecated and is no longer maintained. Please use @rollup/plugin-inject.", + "dev": true, + "dependencies": { + "estree-walker": "^0.6.1", + "magic-string": "^0.25.3", + "rollup-pluginutils": "^2.8.1" + } + }, + "node_modules/rollup-plugin-node-polyfills": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/rollup-plugin-node-polyfills/-/rollup-plugin-node-polyfills-0.2.1.tgz", + "integrity": "sha512-4kCrKPTJ6sK4/gLL/U5QzVT8cxJcofO0OU74tnB19F40cmuAKSzH5/siithxlofFEjwvw1YAhPmbvGNA6jEroA==", + "dev": true, + "dependencies": { + "rollup-plugin-inject": "^3.0.0" + } + }, + "node_modules/rollup-pluginutils": { + "version": "2.8.2", + "resolved": "https://registry.npmjs.org/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz", + "integrity": "sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ==", + "dev": true, + "dependencies": { + "estree-walker": "^0.6.1" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/selfsigned": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/selfsigned/-/selfsigned-2.1.1.tgz", + "integrity": "sha512-GSL3aowiF7wa/WtSFwnUrludWFoNhftq8bUkH9pkzjpN2XSPOAYEgg6e0sS9s0rZwgJzJiQRPU18A6clnoW5wQ==", + "dev": true, + "dependencies": { + "node-forge": "^1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dev": true, + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/simple-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", + "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/simple-get": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", + "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "decompress-response": "^6.0.0", + "once": "^1.3.1", + "simple-concat": "^1.0.0" + } + }, + "node_modules/source-map": { + "version": "0.7.4", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.4.tgz", + "integrity": "sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/source-map-support": { + "version": "0.5.21", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz", + "integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==", + "dev": true, + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/source-map-support/node_modules/source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sourcemap-codec": { + "version": "1.4.8", + "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", + "integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==", + "deprecated": "Please use @jridgewell/sourcemap-codec instead", + "dev": true + }, + "node_modules/stacktracey": { + "version": "2.1.8", + "resolved": "https://registry.npmjs.org/stacktracey/-/stacktracey-2.1.8.tgz", + "integrity": "sha512-Kpij9riA+UNg7TnphqjH7/CzctQ/owJGNbFkfEeve4Z4uxT5+JapVLFXcsurIfN34gnTWZNJ/f7NMG0E8JDzTw==", + "dev": true, + "dependencies": { + "as-table": "^1.0.36", + "get-source": "^2.0.12" + } + }, + "node_modules/stoppable": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/stoppable/-/stoppable-1.1.0.tgz", + "integrity": "sha512-KXDYZ9dszj6bzvnEMRYvxgeTHU74QBFL54XKtP3nyMuJ81CFYtABZ3bAzL2EdFUaEwJOBOgENyFj3R7oTzDyyw==", + "dev": true, + "engines": { + "node": ">=4", + "npm": ">=6" + } + }, + "node_modules/streamsearch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/streamsearch/-/streamsearch-1.1.0.tgz", + "integrity": "sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==", + "dev": true, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dev": true, + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tar-fs": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz", + "integrity": "sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==", + "dev": true, + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.1.4" + } + }, + "node_modules/tar-stream": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", + "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", + "dev": true, + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==", + "dev": true + }, + "node_modules/tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", + "dev": true, + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, + "node_modules/typescript": { + "version": "5.2.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.2.2.tgz", + "integrity": "sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/undici": { + "version": "5.24.0", + "resolved": "https://registry.npmjs.org/undici/-/undici-5.24.0.tgz", + "integrity": "sha512-OKlckxBjFl0oXxcj9FU6oB8fDAaiRUq+D8jrFWGmOfI/gIyjk/IeS75LMzgYKUaeHzLUcYvf9bbJGSrUwTfwwQ==", + "dev": true, + "dependencies": { + "busboy": "^1.6.0" + }, + "engines": { + "node": ">=14.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "dev": true + }, + "node_modules/workerd": { + "version": "1.20230904.0", + "resolved": "https://registry.npmjs.org/workerd/-/workerd-1.20230904.0.tgz", + "integrity": "sha512-t9znszH0rQGK4mJGvF9L3nN0qKEaObAGx0JkywFtAwH8OkSn+YfQbHNZE+YsJ4qa1hOz1DCNEk08UDFRBaYq4g==", + "dev": true, + "hasInstallScript": true, + "bin": { + "workerd": "bin/workerd" + }, + "engines": { + "node": ">=16" + }, + "optionalDependencies": { + "@cloudflare/workerd-darwin-64": "1.20230904.0", + "@cloudflare/workerd-darwin-arm64": "1.20230904.0", + "@cloudflare/workerd-linux-64": "1.20230904.0", + "@cloudflare/workerd-linux-arm64": "1.20230904.0", + "@cloudflare/workerd-windows-64": "1.20230904.0" + } + }, + "node_modules/wrangler": { + "version": "3.8.0", + "resolved": "https://registry.npmjs.org/wrangler/-/wrangler-3.8.0.tgz", + "integrity": "sha512-sTdD+6fMEpM9ROxv+gcyxgTKpnf7tB5ftRV5+wupsdljWkow5C00UCWU/IWSOUfuitAGAj1PWATjKfrRp9Bk9w==", + "dev": true, + "dependencies": { + "@cloudflare/kv-asset-handler": "^0.2.0", + "@esbuild-plugins/node-globals-polyfill": "^0.2.3", + "@esbuild-plugins/node-modules-polyfill": "^0.2.2", + "blake3-wasm": "^2.1.5", + "chokidar": "^3.5.3", + "esbuild": "0.17.19", + "miniflare": "3.20230904.0", + "nanoid": "^3.3.3", + "path-to-regexp": "^6.2.0", + "selfsigned": "^2.0.1", + "source-map": "^0.7.4", + "xxhash-wasm": "^1.0.1" + }, + "bin": { + "wrangler": "bin/wrangler.js", + "wrangler2": "bin/wrangler.js" + }, + "engines": { + "node": ">=16.13.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true + }, + "node_modules/ws": { + "version": "8.14.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.14.1.tgz", + "integrity": "sha512-4OOseMUq8AzRBI/7SLMUwO+FEDnguetSk7KMb1sHwvF2w2Wv5Hoj0nlifx8vtGsftE/jWHojPy8sMMzYLJ2G/A==", + "dev": true, + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xxhash-wasm": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/xxhash-wasm/-/xxhash-wasm-1.0.2.tgz", + "integrity": "sha512-ibF0Or+FivM9lNrg+HGJfVX8WJqgo+kCLDc4vx6xMeTce7Aj+DLttKbxxRR/gNLSAelRc1omAPlJ77N/Jem07A==", + "dev": true + }, + "node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/youch": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/youch/-/youch-3.3.1.tgz", + "integrity": "sha512-Rg9ioi+AkKyje2Hk4qILSVvayaFW98KTsOJ4aIkjDf97LZX5WJVIHZmFLnM4ThcVofHo/fbbwtYajfBPHFOVtg==", + "dev": true, + "dependencies": { + "cookie": "^0.5.0", + "mustache": "^4.2.0", + "stacktracey": "^2.1.8" + } + }, + "node_modules/zod": { + "version": "3.22.2", + "resolved": "https://registry.npmjs.org/zod/-/zod-3.22.2.tgz", + "integrity": "sha512-wvWkphh5WQsJbVk1tbx1l1Ly4yg+XecD+Mq280uBGt9wa5BKSWf4Mhp6GmrkPixhMxmabYY7RbzlwVP32pbGCg==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/colinhacks" + } + } + } +} diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package.json b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package.json new file mode 100644 index 0000000..0e8ba35 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/package.json @@ -0,0 +1,17 @@ +{ + "name": "jwt-authorizer", + "version": "0.0.0", + "private": true, + "scripts": { + "deploy": "wrangler deploy", + "start": "wrangler dev" + }, + "devDependencies": { + "@cloudflare/workers-types": "^4.20230419.0", + "typescript": "^5.0.4", + "wrangler": "^3.0.0" + }, + "dependencies": { + "@tsndr/cloudflare-worker-jwt": "^2.2.2" + } +} diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/src/index.ts b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/src/index.ts new file mode 100644 index 0000000..09aa3aa --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/src/index.ts @@ -0,0 +1,23 @@ + +import jwt from '@tsndr/cloudflare-worker-jwt' + +//Key used for signing and validating JWT's +const secret = `MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAr+2VmwBzzGvrY8F7HsMa/Ffgy0dwhWvJ3Ay8NgjMBfHMrC3Aj2uLKRA588dF8JmAoEsYayikyf9VNum9xRfIzKodrGFX9B6w8TmCE8Z5IjTZ2ecagUHmx6NkxWZnTMho1mNyLpTjC9AGDWSpTBBGHvjuBaY7X6vE0NvcoILdMCbDLTipyMiugHzrG5LqI5Xu8+xc6Cbf0Zjp56fptR71JnpMQJG6ZD6aEX6fZPfb7t2Lwpb+ZpOdQD+2nXYDzNljmrkBDARHOIh/i8RM9Ryae3RQA0KvDHpEbsSl5olspq7Z0mZ9MqJelXptV5fjLnZp6CbSIMNBIUQToJqkms4bpYCHCoGcbDq0+jOIyXiIn4QGZq7Cx88SCFVUud8wErd3FD70W4wO2INkYIEiozSKQwdDzaUcOVpT9thLL45b9kc3hiMm987UJk1MoajQHyay2rycbEdLlhR0qEfaVCMsRzAW43FRzR0KcRJJzlQVsavVwo5Od+/S3tD6poKYyrLRx1PQSx/91agdFCS93+xo9/h+wVzDoes/Ov/GNTSU9qbUE90a4H+594L8Jklqlo0wEgaK+wq2po4cmP5neVXpjtT1leLr4dI2zvQYGVjf2ZnQhl0/OX0EWotRcCtB3TabdX/ldAco/EnRSyKQY0jmXRJ6xrrBtTJ5XD2t+VLkVdUCAwEAAQ==` + +export default { + + async fetch(request: Request) { + + const email = JSON.parse(await request.text())['email'] + + const token = await jwt.sign({ + "https://hasura.io/jwt/claims": { + "x-hasura-default-role": "user", + "x-hasura-allowed-roles": ["user", "admin"], + "x-hasura-user-email-address": email + } + }, secret) + + return new Response(token) + } +}; diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/tsconfig.json b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/tsconfig.json new file mode 100644 index 0000000..2cb9189 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/tsconfig.json @@ -0,0 +1,101 @@ +{ + "compilerOptions": { + /* Visit https://aka.ms/tsconfig.json to read more about this file */ + + /* Projects */ + // "incremental": true, /* Enable incremental compilation */ + // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */ + // "tsBuildInfoFile": "./", /* Specify the folder for .tsbuildinfo incremental compilation files. */ + // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects */ + // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ + // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ + + /* Language and Environment */ + "target": "es2021" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */, + "lib": ["es2021"] /* Specify a set of bundled library declaration files that describe the target runtime environment. */, + "jsx": "react" /* Specify what JSX code is generated. */, + // "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */ + // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ + // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h' */ + // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */ + // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using `jsx: react-jsx*`.` */ + // "reactNamespace": "", /* Specify the object invoked for `createElement`. This only applies when targeting `react` JSX emit. */ + // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ + // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ + + /* Modules */ + "module": "es2022" /* Specify what module code is generated. */, + // "rootDir": "./", /* Specify the root folder within your source files. */ + "moduleResolution": "node" /* Specify how TypeScript looks up a file from a given module specifier. */, + // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */ + // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */ + // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */ + // "typeRoots": [], /* Specify multiple folders that act like `./node_modules/@types`. */ + "types": ["@cloudflare/workers-types"] /* Specify type package names to be included without being referenced in a source file. */, + // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ + "resolveJsonModule": true /* Enable importing .json files */, + // "noResolve": true, /* Disallow `import`s, `require`s or ``s from expanding the number of files TypeScript should add to a project. */ + + /* JavaScript Support */ + "allowJs": true /* Allow JavaScript files to be a part of your program. Use the `checkJS` option to get errors from these files. */, + "checkJs": false /* Enable error reporting in type-checked JavaScript files. */, + // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from `node_modules`. Only applicable with `allowJs`. */ + + /* Emit */ + // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */ + // "declarationMap": true, /* Create sourcemaps for d.ts files. */ + // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */ + // "sourceMap": true, /* Create source map files for emitted JavaScript files. */ + // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If `declaration` is true, also designates a file that bundles all .d.ts output. */ + // "outDir": "./", /* Specify an output folder for all emitted files. */ + // "removeComments": true, /* Disable emitting comments. */ + "noEmit": true /* Disable emitting files from a compilation. */, + // "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */ + // "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types */ + // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */ + // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */ + // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */ + // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */ + // "newLine": "crlf", /* Set the newline character for emitting files. */ + // "stripInternal": true, /* Disable emitting declarations that have `@internal` in their JSDoc comments. */ + // "noEmitHelpers": true, /* Disable generating custom helper functions like `__extends` in compiled output. */ + // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */ + // "preserveConstEnums": true, /* Disable erasing `const enum` declarations in generated code. */ + // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ + // "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */ + + /* Interop Constraints */ + "isolatedModules": true /* Ensure that each file can be safely transpiled without relying on other imports. */, + "allowSyntheticDefaultImports": true /* Allow 'import x from y' when a module doesn't have a default export. */, + // "esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */, + // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */ + "forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */, + + /* Type Checking */ + "strict": true /* Enable all strict type-checking options. */, + // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied `any` type.. */ + // "strictNullChecks": true, /* When type checking, take into account `null` and `undefined`. */ + // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ + // "strictBindCallApply": true, /* Check that the arguments for `bind`, `call`, and `apply` methods match the original function. */ + // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */ + // "noImplicitThis": true, /* Enable error reporting when `this` is given the type `any`. */ + // "useUnknownInCatchVariables": true, /* Type catch clause variables as 'unknown' instead of 'any'. */ + // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ + // "noUnusedLocals": true, /* Enable error reporting when a local variables aren't read. */ + // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read */ + // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ + // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ + // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */ + // "noUncheckedIndexedAccess": true, /* Include 'undefined' in index signature results */ + // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */ + // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type */ + // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */ + // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */ + + /* Completeness */ + // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ + "skipLibCheck": true /* Skip type checking all .d.ts files. */ + } +} diff --git a/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/wrangler.toml b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/wrangler.toml new file mode 100644 index 0000000..25bf2b1 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/jwt-authorizer/wrangler.toml @@ -0,0 +1,51 @@ +name = "jwt-authorizer" +main = "src/index.ts" +compatibility_date = "2023-09-04" + +# Variable bindings. These are arbitrary, plaintext strings (similar to environment variables) +# Note: Use secrets to store sensitive data. +# Docs: https://developers.cloudflare.com/workers/platform/environment-variables +# [vars] +# MY_VARIABLE = "production_value" + +# Bind a KV Namespace. Use KV as persistent storage for small key-value pairs. +# Docs: https://developers.cloudflare.com/workers/runtime-apis/kv +# [[kv_namespaces]] +# binding = "MY_KV_NAMESPACE" +# id = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" + +# Bind an R2 Bucket. Use R2 to store arbitrarily large blobs of data, such as files. +# Docs: https://developers.cloudflare.com/r2/api/workers/workers-api-usage/ +# [[r2_buckets]] +# binding = "MY_BUCKET" +# bucket_name = "my-bucket" + +# Bind a Queue producer. Use this binding to schedule an arbitrary task that may be processed later by a Queue consumer. +# Docs: https://developers.cloudflare.com/queues/get-started +# [[queues.producers]] +# binding = "MY_QUEUE" +# queue = "my-queue" + +# Bind a Queue consumer. Queue Consumers can retrieve tasks scheduled by Producers to act on them. +# Docs: https://developers.cloudflare.com/queues/get-started +# [[queues.consumers]] +# queue = "my-queue" + +# Bind another Worker service. Use this binding to call another Worker without network overhead. +# Docs: https://developers.cloudflare.com/workers/platform/services +# [[services]] +# binding = "MY_SERVICE" +# service = "/api/*" + +# Bind a Durable Object. Durable objects are a scale-to-zero compute primitive based on the actor model. +# Durable Objects can live for as long as needed. Use these when you need a long-running "server", such as in realtime apps. +# Docs: https://developers.cloudflare.com/workers/runtime-apis/durable-objects +# [[durable_objects.bindings]] +# name = "MY_DURABLE_OBJECT" +# class_name = "MyDurableObject" + +# Durable Object migrations. +# Docs: https://developers.cloudflare.com/workers/learning/using-durable-objects#configure-durable-object-classes-with-migrations +# [[migrations]] +# tag = "v1" +# new_classes = ["MyDurableObject"] From ada4802e08618f637ee18a78e908edd340913cf9 Mon Sep 17 00:00:00 2001 From: RomanLachenmayr <142333901+RomanLachenmayr@users.noreply.github.com> Date: Thu, 14 Sep 2023 15:13:13 +0200 Subject: [PATCH 3/8] Create challenge-task.md --- .../micro/frontend/react2/challenge-task.md | 84 +++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 docs/pages/challenges/micro/frontend/react2/challenge-task.md diff --git a/docs/pages/challenges/micro/frontend/react2/challenge-task.md b/docs/pages/challenges/micro/frontend/react2/challenge-task.md new file mode 100644 index 0000000..2c07273 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/challenge-task.md @@ -0,0 +1,84 @@ +# React Challenge 2 🤯 + +Welcome to the React coding challenge 2! In this challenge, your task is to build a frontend for a project management application using React. +We have already built a robust backend for your application service. +This challenge will test your understanding and application of React components, props, states, hooks and more. + +## Requirements + +The application should be able to handle various projects and respective tasks. + +Backend data model: +- Project properties: project_id, email_address, name, description, created_at +- Task properties: task_id, project_id, name, description, created_at, status (enum - OPEN / IN_PROGRESS / DONE) + +Project_id of project, task_id, created_at and email_address are automatically set upon creation and are not mutable. + +### The following functionalities should be provided: +1. Create a new project with a name and a description +2. Edit name and description of a project +3. Delete a project +4. Display all projects +5. Create a new task for an existing project with a project_id, name, description and status. The status is set to OPEN by default. +6. Edit name, description and status of a task +7. Delete a task +8. Display all tasks for a specific project + +The backend provides all necessary methods. + +Additional details: + +- Ensure the implementation is user-friendly with a clean, intuitive user-interface. +- The application should be responsive in design and should work on different screen sizes. +- Thoughtful error handling and loading states for better UX. +- Include comments to explain your implementation approach. + +## What has already been implemented for you ✅ + +The backend uses Hasura to create an API, Postgres as a database, +GraphQL for the requests and Cloudflare workers to generate JWTs (https://jwt.io/introduction) needed for authorization. + + +Each project is exclusively mapped to a single user through their email-address. By that, the respective tasks are restricted to the creator of the project as well. +Users can only create, access, edit and delete their own projects and therefore tasks. +This is guaranteed by the Hasura JWT Authentication service (https://hasura.io/docs/latest/auth/authentication/jwt/). + + +The flow is as follows: + +First, a HTTP post request must be sent to this url: *** . +The body of the request must be in JSON and include a parameter called “email” with the value of the user’s email address. + +``` +{ + "email": "test@selectcode.de" +} +``` +With this request a JWT for the authentification of the user is generated and sent back in the body of the response. +This token has to be included in the request header of each GraphQL query/mutation. Else, access will be denied. 😈 + +The requests have to be sent to this URL: https://react-challenge.deploy.selectcode.dev/v1/graphql. +One of the header titles of each request must be set to "Authorization" and the value to "Bearer ". + + + +## Definition of done 🎉 + +For completing this challenge, please ensure that you meet the following requirements: +- Your React application fulfills all described functional requirements. +- A README.md file explains how to install any necessary dependencies and how to run your application. +Please also include a short description and explanation of the main aspects of your chosen approaches. + +As soon as you have finished both other challenges, please submit your solution in our online form. + +## Evaluation criteria 🔎 + +We will evaluate your work based on the following: +- Functional fit: How well the functional requirements are fulfilled. +- Design: We’re looking for a user-friendly and intuitive design. +- Responsive design: How well your page adapts to different screen sizes. +- Code quality: We're looking for clean, readable, and well-structured code. +- Documentation quality: We're looking for a well-structured README.md file that contains all necessary information as well as well-documented code. +- Problem solving: Remember, we're not just interested in the final product - we want to see how you got there. Commit early and often, with clear and informative commit messages. + +Good luck with your coding — and remember to enjoy the process! 🚀 From d46852447fad6d2912595b81397bdd4a1a3b2db6 Mon Sep 17 00:00:00 2001 From: RomanLachenmayr <142333901+RomanLachenmayr@users.noreply.github.com> Date: Thu, 14 Sep 2023 15:28:16 +0200 Subject: [PATCH 4/8] Update challenge-task.md --- .../pages/challenges/micro/frontend/react2/challenge-task.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/docs/pages/challenges/micro/frontend/react2/challenge-task.md b/docs/pages/challenges/micro/frontend/react2/challenge-task.md index 2c07273..fb1c249 100644 --- a/docs/pages/challenges/micro/frontend/react2/challenge-task.md +++ b/docs/pages/challenges/micro/frontend/react2/challenge-task.md @@ -58,7 +58,7 @@ With this request a JWT for the authentification of the user is generated and se This token has to be included in the request header of each GraphQL query/mutation. Else, access will be denied. 😈 The requests have to be sent to this URL: https://react-challenge.deploy.selectcode.dev/v1/graphql. -One of the header titles of each request must be set to "Authorization" and the value to "Bearer ". +One of the header titles of each request must be set to "Authorization" and the value to "Bearer < JWT > ". @@ -75,8 +75,7 @@ As soon as you have finished both other challenges, please submit your solution We will evaluate your work based on the following: - Functional fit: How well the functional requirements are fulfilled. -- Design: We’re looking for a user-friendly and intuitive design. -- Responsive design: How well your page adapts to different screen sizes. +- Design: We’re looking for a user-friendly and intuitive design. Moreover, your page should adapt to different screen sizes. - Code quality: We're looking for clean, readable, and well-structured code. - Documentation quality: We're looking for a well-structured README.md file that contains all necessary information as well as well-documented code. - Problem solving: Remember, we're not just interested in the final product - we want to see how you got there. Commit early and often, with clear and informative commit messages. From d22b474ecc29cbd20acf97d55c29ef0b16eb6b72 Mon Sep 17 00:00:00 2001 From: RomanLachenmayr <142333901+RomanLachenmayr@users.noreply.github.com> Date: Thu, 14 Sep 2023 15:33:38 +0200 Subject: [PATCH 5/8] Update challenge-task.md json formatting for example json --- docs/pages/challenges/micro/frontend/react2/challenge-task.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/pages/challenges/micro/frontend/react2/challenge-task.md b/docs/pages/challenges/micro/frontend/react2/challenge-task.md index fb1c249..74fb472 100644 --- a/docs/pages/challenges/micro/frontend/react2/challenge-task.md +++ b/docs/pages/challenges/micro/frontend/react2/challenge-task.md @@ -49,7 +49,7 @@ The flow is as follows: First, a HTTP post request must be sent to this url: *** . The body of the request must be in JSON and include a parameter called “email” with the value of the user’s email address. -``` +```json { "email": "test@selectcode.de" } From 9933037208a675164944e96734e90264c08b1d82 Mon Sep 17 00:00:00 2001 From: matteomrz <131947443+matteomrz@users.noreply.github.com> Date: Thu, 14 Sep 2023 15:57:25 +0200 Subject: [PATCH 6/8] YAML file with GraphQL queries and mutations --- .../react2/ReactChallenge2Insomnia.yaml | 550 ++++++++++++++++++ 1 file changed, 550 insertions(+) create mode 100644 docs/pages/challenges/micro/frontend/react2/ReactChallenge2Insomnia.yaml diff --git a/docs/pages/challenges/micro/frontend/react2/ReactChallenge2Insomnia.yaml b/docs/pages/challenges/micro/frontend/react2/ReactChallenge2Insomnia.yaml new file mode 100644 index 0000000..586ad68 --- /dev/null +++ b/docs/pages/challenges/micro/frontend/react2/ReactChallenge2Insomnia.yaml @@ -0,0 +1,550 @@ +_type: export +__export_format: 4 +__export_date: 2023-09-14T13:23:55.173Z +__export_source: insomnia.desktop.app:v2023.5.8 +resources: + - _id: req_58dade89fe4a4764962c1a585504d720 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694684308467 + created: 1694684256230 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: updateTaskStatus + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation updateTaskStatus($task_id: Int!, $status: + status_type_enum = OPEN) {\n update_tasks_by_pk(pk_columns: {task_id: + $task_id}, _set: {status: $status}) + {\n created_at\n description\n name\n project_id\n status\n task_id\n }\n}","operationName":"updateTaskStatus"}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_b1711055017848c1b04ada4768a71e45 + - name: Content-Type + value: application/json + id: pair_66e6e3770b834b9daa6fa70e1b2ef528 + - id: pair_5436c24f5d5e4ac5bb8040467fb61a35 + name: Authorization + value: "" + description: "" + authentication: {} + metaSortKey: -1694684225265.5 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: fld_a3cedb75293c4d939e403c7a59a4225f + parentId: wrk_706d316fda584061b26e9868e04d5fa8 + modified: 1694611181024 + created: 1694611181024 + name: TaskRequests + description: "" + environment: {} + environmentPropertyOrder: null + metaSortKey: -1694611181024 + _type: request_group + - _id: wrk_706d316fda584061b26e9868e04d5fa8 + parentId: null + modified: 1694697823763 + created: 1694597105414 + name: ReactChallenge2.yaml + description: "" + scope: design + _type: workspace + - _id: req_d5dccfab0e534d64a2b7f6a40a578780 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694684306262 + created: 1694684206728 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: updateTaskDescription + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation updateTaskDescription($task_id: Int!, $description: + String!) {\n update_tasks_by_pk(pk_columns: {task_id: $task_id}, _set: + {description: $description}) + {\n created_at\n description\n name\n project_id\n status\n task_id\n }\n}","operationName":"updateTaskDescription"}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_7c7170ad2b6f420c990285c2f9689f44 + - name: Content-Type + value: application/json + id: pair_0bb162a4a2824998bf823ba9ff508737 + - id: pair_62642547fab842379ef7baea03f24c35 + name: Authorization + value: "" + description: "" + authentication: {} + metaSortKey: -1694684206728 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_06628597200240669b28ef3aae603b46 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694693353288 + created: 1694684171179 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: updateTaskName + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation updateTaskName($task_id: Int!, $name: String!) + {\n update_tasks_by_pk(pk_columns: {task_id: $task_id}, _set: {name: + $name}) + {\n created_at\n description\n name\n project_id\n status\n task_id\n }\n}","operationName":"updateTaskName","variables":{"task_id":5,"name":"hahaha"}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_115c478d198942d6a056f0b5f7cf4e14 + - name: Content-Type + value: application/json + id: pair_96e17a75d0d5495187efe0f83b7c14db + - id: pair_98f925c472b44c7984160ca5df6860cd + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: {} + metaSortKey: -1694684171179 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_d35011e6d3b94a4aa14936c9551ad3d6 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694693303107 + created: 1694683970838 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: getTaskById + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"query getTaskById($task_id: Int!) {\n tasks_by_pk(task_id: + $task_id) + {\n created_at\n description\n name\n project_id\n status\n task_id\n project + {\n name\n }\n }\n}","operationName":"getTaskById","variables":{"task_id":5}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_d67ecb6f53024a38a021fac45e2adfc4 + - name: Content-Type + value: application/json + id: pair_f632c82ce9004091a4354b9239c1dec4 + - id: pair_de8d702f8e8c47f19a4407f6ae527027 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + - id: pair_8ae8a55cbc8e4da1abf1f5f0b1e395ef + name: "" + value: "" + description: "" + authentication: {} + metaSortKey: -1694683970838 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_efe6ce46bb64447083b702e3ec3ad2d3 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694696474457 + created: 1694614225380 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: deleteTask + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation deleteTask($task_id: Int!) + {\n delete_tasks_by_pk(task_id: $task_id) + {\n created_at\n description\n name\n project_id\n status\n task_id\n }\n}","operationName":"deleteTask","variables":{"task_id":5}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_e24708878c7a4454b73dad28d70db4a0 + - name: Content-Type + value: application/json + id: pair_403782f489b5483eab193cbea95f0de6 + - id: pair_dc0fcc1e61b7498181a55d57a6911f09 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + - id: pair_7ca3a66a28684d4d913f188d51ab6b40 + name: "" + value: "" + description: "" + authentication: + type: bearer + metaSortKey: -1694614170345.5 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_c36c7cfe72084913aa9bc163fb3f0288 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694693132732 + created: 1694614115311 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: addTask + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation addTask($description: String!, $name: String!, + $project_id: Int!, $status: status_type_enum = OPEN) + {\n insert_tasks_one(object: {description: $description, name: $name, + project_id: $project_id, status: $status}) + {\n created_at\n description\n name\n project_id\n status\n task_id\n }\n}","operationName":"addTask","variables":{"description":"ahjdgk","name":"fjkdald","project_id":28}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_8abc5924c57243b2bdbbbadfd1a1188b + - name: Content-Type + value: application/json + id: pair_3ec4138b6e7141c494154bc7b8b8300b + - id: pair_68290dc1b5164d049a4934ff5730aeb9 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: + type: bearer + metaSortKey: -1694614115311 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_d73e04d9d3af424ea46e40d5c8c73bb6 + parentId: fld_a3cedb75293c4d939e403c7a59a4225f + modified: 1694693244587 + created: 1694613858301 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: getTasks + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"query getTasks {\n\ttasks + {\n\t\tdescription\n\t\tname\n\t\tproject_id\n\t\tstatus\n\t\ttask_id\n\t}\n}\n","operationName":"getTasks"}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_eb5af0c197db4f74b6edc1dbad245f61 + - name: Content-Type + value: application/json + id: pair_b877b989f7734e51bbfe2ae29cfd6246 + - id: pair_4c4d086e8f3345e3aacc321a27e387f4 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: + type: bearer + metaSortKey: -1694613858301 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_608a530c7fff44808af46e701696a292 + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694693215449 + created: 1694614082501 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: getProjectAndTasksByProjectId + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"query getProjectAndTasksByProjectId($project_id: Int!) + {\n projects(where: {project_id: {_eq: $project_id}}) + {\n created_at\n description\n email_address\n name\n project_id\n tasks + {\n created_at\n description\n name\n status\n task_id\n }\n }\n}","operationName":"getProjectAndTasksByProjectId","variables":{"project_id":28}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_dd4e7783d2474ecc93de5edb3f7e2d7b + - name: Content-Type + value: application/json + id: pair_2ad7b488e7cb4bb0b594b9e89ea3fc45 + - id: pair_29fb034cb9f64e0688bcb4382ad9c209 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: + type: bearer + metaSortKey: -1694684096254 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: fld_a8e6e58ec8264fb4a69f346f4072a0ad + parentId: wrk_706d316fda584061b26e9868e04d5fa8 + modified: 1694611170735 + created: 1694611170735 + name: ProjectRequests + description: "" + environment: {} + environmentPropertyOrder: null + metaSortKey: -1694611170735 + _type: request_group + - _id: req_63c1c110965c486986dd0c6f3a7683a6 + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694684289823 + created: 1694684096154 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: updateProjectDescription + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation updateProjectDescription($project_id: Int!, + $description: String!) {\n update_projects_by_pk(pk_columns: + {project_id: $project_id}, _set: {description: $description}) + {\n created_at\n description\n email_address\n name\n project_id\n }\n}","operationName":"updateProjectDescription"}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_68be6168d2214358b414ca9276d9b2c9 + - name: Content-Type + value: application/json + id: pair_2fbae2b5e7e44923a71604ebe4f419a9 + - id: pair_67fc20bddb8943f4b5c73d2b08b697e1 + name: Authorization + value: "" + description: "" + authentication: {} + metaSortKey: -1694684096154 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_1d226e23cc414859a985e412ceb464e2 + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694692798837 + created: 1694684042160 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: updateProjectName + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation updateProjectName($project_id: Int!, $name: String!) + {\n\tupdate_projects_by_pk(\n\t\tpk_columns: { project_id: $project_id + }\n\t\t_set: { name: $name }\n\t) + {\n\t\tcreated_at\n\t\tdescription\n\t\temail_address\n\t\tname\n\t\tproject_id\n\t}\n}\n","operationName":"updateProjectName","variables":{"project_id":27,"name":"changed"}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_a2cfd9168e554256a64695d92b339cbb + - name: Content-Type + value: application/json + id: pair_f36687cbde3b43f0befea1feb0a5edc1 + - id: pair_f964b1ccf357476293b1898834d3a7b0 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: {} + metaSortKey: -1694684042160 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_1263fd435abb4f44a3743710c58f1fb5 + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694692981262 + created: 1694611879819 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: deleteProject + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation deleteProject($project_id: Int!) + {\n delete_projects_by_pk(project_id: $project_id) {\n tasks + {\n project_id\n\t\t\ttask_id\n name\n }\n name\n email_address\n project_id\n description\n created_at\n }\n}","operationName":"deleteProject","variables":{"project_id":27}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_e464f4356b004c07a6d3f0e217aeb9e7 + - name: Content-Type + value: application/json + id: pair_a0e04eb0651a4e6e844fc008fc105d44 + - id: pair_54e90936c14c4acab783bb390a1475d4 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: + type: bearer + token: "" + metaSortKey: -1694611879819 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_24069c464b634c4ab21c77ecde779b43 + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694692668248 + created: 1694611307379 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: addProject + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"mutation addProject($description: String!, $name: String!) + {\n insert_projects_one(object: {description: $description, name: + $name}) + {\n created_at\n description\n email_address\n name\n project_id\n }\n}","operationName":"addProject","variables":{"name":"Projekt3","description":"Beispiel1"}}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_1e9beb9d2434437e9664618e14bb7e7f + - name: Content-Type + value: application/json + id: pair_a6ab9b5e13894c6c81e3babf85697c7e + - id: pair_39054cb9afa946ad8eb49067927adfcb + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + - id: pair_162ac6add22446d58260d3b0d1c952c4 + name: "" + value: "" + description: "" + authentication: {} + metaSortKey: -1694611307379 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: req_e9fb1ee77bb64f8bad69a9f2548f8f9e + parentId: fld_a8e6e58ec8264fb4a69f346f4072a0ad + modified: 1694692600375 + created: 1694611226437 + url: https://react-challenge.deploy.selectcode.dev/v1/graphql + name: getProjects + description: "" + method: POST + body: + mimeType: application/graphql + text: '{"query":"query getProjects {\n projects + {\n project_id\n name\n description\n created_at\n email_address\n project_id\n }\n}","operationName":"getProjects"}' + parameters: [] + headers: + - name: User-Agent + value: insomnia/2023.5.8 + id: pair_9dc2bf4c60b24a4f897003548154ddf5 + - name: Content-Type + value: application/json + id: pair_27730441284b49aca02d5689ce6d8866 + - id: pair_b2cae90264994b00850b057e948fc224 + name: Authorization + value: Bearer + eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJkb21pbmlrLnN0b3Jja0BzZWxlY3Rjb2RlLmRlIn0sImlhdCI6MTY5NDYxMzYxMn0.Y_QqXpI_bMZ4GMyA8vG1lZPYU8QpL_APwNdJs7eLRJ4 + description: "" + authentication: {} + metaSortKey: -1694611226437 + isPrivate: false + settingStoreCookies: true + settingSendCookies: true + settingDisableRenderRequestBody: false + settingEncodeUrl: true + settingRebuildPath: true + settingFollowRedirects: global + _type: request + - _id: env_b36222d7e1f95a0d4cbe728a3ade8c64b63d5f9e + parentId: wrk_706d316fda584061b26e9868e04d5fa8 + modified: 1694597105422 + created: 1694597105422 + name: Base Environment + data: {} + dataPropertyOrder: null + color: null + isPrivate: false + metaSortKey: 1694597105422 + _type: environment + - _id: jar_b36222d7e1f95a0d4cbe728a3ade8c64b63d5f9e + parentId: wrk_706d316fda584061b26e9868e04d5fa8 + modified: 1694597105425 + created: 1694597105425 + name: Default Jar + cookies: [] + _type: cookie_jar + - _id: spc_c26e2e22adbd4a3c9355a3e779de8cae + parentId: wrk_706d316fda584061b26e9868e04d5fa8 + modified: 1694697823761 + created: 1694597105419 + fileName: ReactChallenge2.yaml + contents: "" + contentType: yaml + _type: api_spec From 27513b98a7aa12f45784221dc9866d88d3854a85 Mon Sep 17 00:00:00 2001 From: matteomrz <131947443+matteomrz@users.noreply.github.com> Date: Thu, 14 Sep 2023 16:08:27 +0200 Subject: [PATCH 7/8] Update challenge-task.md --- docs/pages/challenges/micro/frontend/react2/challenge-task.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/pages/challenges/micro/frontend/react2/challenge-task.md b/docs/pages/challenges/micro/frontend/react2/challenge-task.md index 74fb472..a2bcc62 100644 --- a/docs/pages/challenges/micro/frontend/react2/challenge-task.md +++ b/docs/pages/challenges/micro/frontend/react2/challenge-task.md @@ -24,7 +24,8 @@ Project_id of project, task_id, created_at and email_address are automatically s 7. Delete a task 8. Display all tasks for a specific project -The backend provides all necessary methods. +The backend provides all necessary methods. You can take a look at them in the included [.yaml file](ReactChallenge2Insomnia.yaml). Best to be opened in Insomnia (https://insomnia.rest/download). + Additional details: From 23d11187cb032ee125f4ddb5994bfbd1f9a68ef6 Mon Sep 17 00:00:00 2001 From: RomanLachenmayr <142333901+RomanLachenmayr@users.noreply.github.com> Date: Tue, 19 Sep 2023 16:30:21 +0200 Subject: [PATCH 8/8] Update challenge-task.md --- .../micro/frontend/react2/challenge-task.md | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/docs/pages/challenges/micro/frontend/react2/challenge-task.md b/docs/pages/challenges/micro/frontend/react2/challenge-task.md index a2bcc62..ced3cf1 100644 --- a/docs/pages/challenges/micro/frontend/react2/challenge-task.md +++ b/docs/pages/challenges/micro/frontend/react2/challenge-task.md @@ -20,9 +20,10 @@ Project_id of project, task_id, created_at and email_address are automatically s 3. Delete a project 4. Display all projects 5. Create a new task for an existing project with a project_id, name, description and status. The status is set to OPEN by default. -6. Edit name, description and status of a task -7. Delete a task -8. Display all tasks for a specific project +6. Edit name and description of a task +7. Change the status of a task +8. Delete a task +9. Display all tasks for a specific project The backend provides all necessary methods. You can take a look at them in the included [.yaml file](ReactChallenge2Insomnia.yaml). Best to be opened in Insomnia (https://insomnia.rest/download). @@ -39,9 +40,11 @@ Additional details: The backend uses Hasura to create an API, Postgres as a database, GraphQL for the requests and Cloudflare workers to generate JWTs (https://jwt.io/introduction) needed for authorization. +![Unbenanntes Diagramm](https://github.com/SelectCode/apply/assets/142333901/b1b6f3b3-5d61-43df-9526-773d13b1589b) + Each project is exclusively mapped to a single user through their email-address. By that, the respective tasks are restricted to the creator of the project as well. -Users can only create, access, edit and delete their own projects and therefore tasks. +Users can only create, access, edit and delete their own projects and taks and do not have access to the projects and tasks of other users. This is guaranteed by the Hasura JWT Authentication service (https://hasura.io/docs/latest/auth/authentication/jwt/). @@ -61,6 +64,10 @@ This token has to be included in the request header of each GraphQL query/mutati The requests have to be sent to this URL: https://react-challenge.deploy.selectcode.dev/v1/graphql. One of the header titles of each request must be set to "Authorization" and the value to "Bearer < JWT > ". +``` +Authorization Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJodHRwczovL2hhc3VyYS5pby9qd3QvY2xhaW1zIjp7IngtaGFzdXJhLWRlZmF1bHQtcm9sZSI6InVzZXIiLCJ4LWhhc3VyYS1hbGxvd2VkLXJvbGVzIjpbInVzZXIiLCJhZG1pbiJdLCJ4LWhhc3VyYS11c2VyLWVtYWlsLWFkZHJlc3MiOiJ0ZXN0QHNlbGVjdGNvZGUuZGUifSwiaWF0IjoxNjk1MTMyMjg4fQ.ytE-IrCfyKJOBVB5x-yWw8bTDHgmaGQ3RBtmeeXwXvw +``` + ## Definition of done 🎉