mirror of
https://github.com/honojs/hono.git
synced 2024-11-24 02:07:30 +01:00
refactor: refine directory structure (#156)
* refactor: refine importing mechanism * refactor: move `CODE_OF_CONDUCT.md`
This commit is contained in:
parent
6d5bbc721a
commit
ac713c0659
15
.eslintrc.js
15
.eslintrc.js
@ -40,19 +40,8 @@ module.exports = defineConfig({
|
||||
},
|
||||
},
|
||||
],
|
||||
'node/no-missing-import': [
|
||||
'error',
|
||||
{
|
||||
allowModules: ['types', 'estree', 'testUtils', 'less', 'sass', 'stylus'],
|
||||
tryExtensions: ['.ts', '.js', '.jsx', '.tsx', '.d.ts'],
|
||||
},
|
||||
],
|
||||
'node/no-missing-require': [
|
||||
'error',
|
||||
{
|
||||
tryExtensions: ['.ts', '.js', '.jsx', '.tsx', '.d.ts'],
|
||||
},
|
||||
],
|
||||
'node/no-missing-import': 'off',
|
||||
'node/no-missing-require': 'off',
|
||||
'node/no-deprecated-api': 'off',
|
||||
'node/no-unpublished-import': 'off',
|
||||
'node/no-unpublished-require': 'off',
|
||||
|
@ -2,5 +2,7 @@ examples
|
||||
benchmark
|
||||
.github
|
||||
tsconfig.json
|
||||
tsconfig.build.json
|
||||
src
|
||||
docs
|
||||
docs
|
||||
yarn.lock
|
@ -3,6 +3,10 @@ module.exports = {
|
||||
transform: {
|
||||
'^.+\\.(ts|tsx)$': 'ts-jest',
|
||||
},
|
||||
modulePaths: ['<rootDir>/src'],
|
||||
moduleNameMapper: {
|
||||
'^@/(.*)$': '<rootDir>/src/$1',
|
||||
},
|
||||
testPathIgnorePatterns: ['./examples'],
|
||||
testEnvironment: 'miniflare',
|
||||
testEnvironmentOptions: {
|
||||
|
67
package.json
67
package.json
@ -10,63 +10,61 @@
|
||||
"scripts": {
|
||||
"test": "jest",
|
||||
"lint": "eslint --ext js,ts src .eslintrc.js && prettier --check src",
|
||||
"build": "rimraf dist && tsc",
|
||||
"watch": "tsc -w",
|
||||
"build": "rimraf dist && tsc --project tsconfig.build.json && tsc-alias -p tsconfig.build.json",
|
||||
"watch": "tsc -w --project tsconfig.build.json & tsc-alias -w -p tsconfig.build.json",
|
||||
"prepublishOnly": "yarn build"
|
||||
},
|
||||
"exports": {
|
||||
".": "./dist/index.js",
|
||||
"./basic-auth": "./dist/middleware/basic-auth/basic-auth.js",
|
||||
"./body-parse": "./dist/middleware/body-parse/body-parse.js",
|
||||
"./cookie": "./dist/middleware/cookie/cookie.js",
|
||||
"./cors": "./dist/middleware/cors/cors.js",
|
||||
"./etag": "./dist/middleware/etag/etag.js",
|
||||
"./graphql-server": "./dist/middleware/graphql-server/graphql-server.js",
|
||||
"./logger": "./dist/middleware/logger/logger.js",
|
||||
"./mustache": "./dist/middleware/mustache/mustache.js",
|
||||
"./powered-by": "./dist/middleware/powered-by/powered-by.js",
|
||||
"./pretty-json": "./dist/middleware/pretty-json/pretty-json.js",
|
||||
"./serve-static": "./dist/middleware/serve-static/serve-static.js",
|
||||
"./router/trie-router": "./dist/router/trie-router/router.js",
|
||||
"./router/reg-exp-router": "./dist/router/reg-exp-router/index.js",
|
||||
"./utils/cloudflare": "./dist/utils/cloudflare.js",
|
||||
"./utils/crypto": "./dist/utils/crypto.js",
|
||||
"./utils/mime": "./dist/utils/mime.js"
|
||||
"./basic-auth": "./dist/middleware/basic-auth",
|
||||
"./body-parse": "./dist/middleware/body-parse",
|
||||
"./cookie": "./dist/middleware/cookie",
|
||||
"./cors": "./dist/middleware/cors",
|
||||
"./etag": "./dist/middleware/etag",
|
||||
"./graphql-server": "./dist/middleware/graphql-server",
|
||||
"./logger": "./dist/middleware/logger",
|
||||
"./mustache": "./dist/middleware/mustache",
|
||||
"./powered-by": "./dist/middleware/powered-by",
|
||||
"./pretty-json": "./dist/middleware/pretty-json",
|
||||
"./serve-static": "./dist/middleware/serve-static",
|
||||
"./router/trie-router": "./dist/router/trie-router",
|
||||
"./router/reg-exp-router": "./dist/router/reg-exp-router",
|
||||
"./utils/*": "./dist/utils/*.js"
|
||||
},
|
||||
"typesVersions": {
|
||||
"*": {
|
||||
"basic-auth": [
|
||||
"./dist/middleware/basic-auth/basic-auth.d.ts"
|
||||
"./dist/middleware/basic-auth"
|
||||
],
|
||||
"body-parse": [
|
||||
"./dist/middleware/body-parse/body-parse.d.ts"
|
||||
"./dist/middleware/body-parse"
|
||||
],
|
||||
"cookie": [
|
||||
"./dist/middleware/cookie/cookie.d.ts"
|
||||
"./dist/middleware/cookie"
|
||||
],
|
||||
"cors": [
|
||||
"./dist/middleware/cors/cors.d.ts"
|
||||
"./dist/middleware/cors"
|
||||
],
|
||||
"etag": [
|
||||
"./dist/middleware/etag/etag.d.ts"
|
||||
"./dist/middleware/etag"
|
||||
],
|
||||
"graphql-server": [
|
||||
"./dist/middleware/graphql-server/graphql-server.d.ts"
|
||||
"./dist/middleware/graphql-server"
|
||||
],
|
||||
"logger": [
|
||||
"./dist/middleware/logger/logger.d.ts"
|
||||
"./dist/middleware/logger"
|
||||
],
|
||||
"mustache": [
|
||||
"./dist/middleware/mustache/mustache.d.ts"
|
||||
"./dist/middleware/mustache"
|
||||
],
|
||||
"powered-by": [
|
||||
"./dist/middleware/powered-by/powered-by.d.ts"
|
||||
"./dist/middleware/powered-by"
|
||||
],
|
||||
"pretty-json": [
|
||||
"./dist/middleware/pretty-json/pretty-json.d.ts"
|
||||
"./dist/middleware/pretty-json"
|
||||
],
|
||||
"serve-static": [
|
||||
"./dist/middleware/serve-static/serve-static.d.ts"
|
||||
"./dist/middleware/serve-static"
|
||||
],
|
||||
"router/trie-router": [
|
||||
"./dist/router/trie-router/router.d.ts"
|
||||
@ -74,14 +72,8 @@
|
||||
"router/reg-exp-router": [
|
||||
"./dist/router/reg-exp-router/router.d.ts"
|
||||
],
|
||||
"utils/cloudflare": [
|
||||
"./dist/utils/cloudflare.d.ts"
|
||||
],
|
||||
"utils/crypto": [
|
||||
"./dist/utils/crypto.d.ts"
|
||||
],
|
||||
"utils/mime": [
|
||||
"./dist/utils/mime.d.ts"
|
||||
"utils/*": [
|
||||
"./dist/utils/*"
|
||||
]
|
||||
}
|
||||
},
|
||||
@ -130,6 +122,7 @@
|
||||
"prettier-plugin-md-nocjsp": "^1.2.0",
|
||||
"rimraf": "^3.0.2",
|
||||
"ts-jest": "^27.1.2",
|
||||
"tsc-alias": "^1.6.6",
|
||||
"typescript": "^4.5.5"
|
||||
},
|
||||
"engines": {
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { compose } from './compose'
|
||||
import { Context } from './context'
|
||||
import { compose } from '@/compose'
|
||||
import { Context } from '@/context'
|
||||
|
||||
type C = {
|
||||
req: Record<string, string>
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { Context } from './context'
|
||||
import type { ErrorHandler } from './hono'
|
||||
import { Context } from '@/context'
|
||||
import type { ErrorHandler } from '@/hono'
|
||||
|
||||
// Based on the code in the MIT licensed `koa-compose` package.
|
||||
export const compose = <C>(middleware: Function[], onError?: ErrorHandler) => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Context } from './context'
|
||||
import { Context } from '@/context'
|
||||
|
||||
describe('Context', () => {
|
||||
const req = new Request('http://localhost/')
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { isAbsoluteURL } from './utils/url'
|
||||
import { getStatusText } from './utils/http-status'
|
||||
import { isAbsoluteURL } from '@/utils/url'
|
||||
import { getStatusText } from '@/utils/http-status'
|
||||
|
||||
type Headers = Record<string, string>
|
||||
type Data = string | ArrayBuffer | ReadableStream
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Hono } from './hono'
|
||||
import { Hono } from '@/hono'
|
||||
|
||||
describe('GET Request', () => {
|
||||
const app = new Hono()
|
||||
|
14
src/hono.ts
14
src/hono.ts
@ -1,10 +1,10 @@
|
||||
import { compose } from './compose'
|
||||
import { getPathFromURL, mergePath } from './utils/url'
|
||||
import { Context } from './context'
|
||||
import type { Env } from './context'
|
||||
import type { Result, Router } from './router'
|
||||
import { METHOD_NAME_OF_ALL } from './router'
|
||||
import { TrieRouter } from './router/trie-router' // Default Router
|
||||
import { compose } from '@/compose'
|
||||
import { getPathFromURL, mergePath } from '@/utils/url'
|
||||
import { Context } from '@/context'
|
||||
import { METHOD_NAME_OF_ALL } from '@/router'
|
||||
import { TrieRouter } from '@/router/trie-router' // Default Router
|
||||
import type { Env } from '@/context'
|
||||
import type { Result, Router } from '@/router'
|
||||
|
||||
declare global {
|
||||
interface Request<ParamKeyType = string> {
|
||||
|
@ -1,4 +1,4 @@
|
||||
export { Hono } from './hono'
|
||||
export type { Handler, MiddlewareHandler } from './hono'
|
||||
export { Context } from './context'
|
||||
export type { Env } from './context'
|
||||
export { Hono } from '@/hono'
|
||||
export type { Handler, MiddlewareHandler } from '@/hono'
|
||||
export { Context } from '@/context'
|
||||
export type { Env } from '@/context'
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { basicAuth } from './basic-auth'
|
||||
import { Hono } from '@/hono'
|
||||
import { basicAuth } from '@/middleware/basic-auth'
|
||||
import { SHA256 } from 'crypto-js'
|
||||
|
||||
describe('Basic Auth by Middleware', () => {
|
@ -1,6 +1,6 @@
|
||||
import type { Context } from '../../context'
|
||||
import { timingSafeEqual } from '../../utils/buffer'
|
||||
import { decodeBase64 } from '../../utils/crypto'
|
||||
import type { Context } from '@/context'
|
||||
import { timingSafeEqual } from '@/utils/buffer'
|
||||
import { decodeBase64 } from '@/utils/crypto'
|
||||
|
||||
const CREDENTIALS_REGEXP = /^ *(?:[Bb][Aa][Ss][Ii][Cc]) +([A-Za-z0-9._~+/-]+=*) *$/
|
||||
const USER_PASS_REGEXP = /^([^:]*):(.*)$/
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { bodyParse } from './body-parse'
|
||||
import { Hono } from '@/hono'
|
||||
import { bodyParse } from '@/middleware/body-parse'
|
||||
|
||||
describe('Parse Body Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { cookie } from './cookie'
|
||||
import { Hono } from '@/hono'
|
||||
import { cookie } from '@/middleware/cookie'
|
||||
|
||||
describe('Cookie Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,4 +1,4 @@
|
||||
import type { Context } from '../../context'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
declare global {
|
||||
interface Request {
|
||||
@ -6,7 +6,7 @@ declare global {
|
||||
}
|
||||
}
|
||||
|
||||
declare module '../../context' {
|
||||
declare module '@/context' {
|
||||
interface Context {
|
||||
cookie: (name: string, value: string, options?: CookieOptions) => void
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { cors } from './cors'
|
||||
import { Hono } from '@/hono'
|
||||
import { cors } from '@/middleware/cors'
|
||||
|
||||
describe('CORS by Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { etag } from './etag'
|
||||
import { Hono } from '@/hono'
|
||||
import { etag } from '@/middleware/etag'
|
||||
|
||||
describe('Etag Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,6 +1,6 @@
|
||||
import { sha1 } from '../../utils/crypto'
|
||||
import { parseBody } from '../../utils/body'
|
||||
import type { Context } from '../../context'
|
||||
import { sha1 } from '@/utils/crypto'
|
||||
import { parseBody } from '@/utils/body'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
type ETagOptions = {
|
||||
weak: boolean
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { errorMessages, graphqlServer } from './graphql-server'
|
||||
import { Hono } from '@/hono'
|
||||
import { errorMessages, graphqlServer } from '@/middleware/graphql-server'
|
||||
import {
|
||||
buildSchema,
|
||||
GraphQLSchema,
|
@ -1,8 +1,8 @@
|
||||
// Based on the code in the `express-graphql` package.
|
||||
// https://github.com/graphql/express-graphql/blob/main/src/index.ts
|
||||
|
||||
import { parseBody } from './parse-body'
|
||||
import type { Context } from '../../context'
|
||||
import { parseBody } from '@/middleware/graphql-server/parse-body'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
import {
|
||||
Source,
|
@ -1,4 +1,4 @@
|
||||
import { parseBody } from './parse-body'
|
||||
import { parseBody } from '@/middleware/graphql-server/parse-body'
|
||||
|
||||
describe('parseBody', () => {
|
||||
it('Should return a blank JSON object', async () => {
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { logger } from './logger'
|
||||
import { Hono } from '@/hono'
|
||||
import { logger } from '@/middleware/logger'
|
||||
|
||||
describe('Logger by Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,5 +1,5 @@
|
||||
import { getPathFromURL } from '../../utils/url'
|
||||
import type { Context } from '../../context'
|
||||
import { getPathFromURL } from '@/utils/url'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
const humanize = (n: string[], opts?: { delimiter?: string; separator?: string }) => {
|
||||
const options = opts || {}
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { mustache } from './mustache'
|
||||
import { Hono } from '@/hono'
|
||||
import { mustache } from '@/middleware/mustache'
|
||||
|
||||
// Mock
|
||||
const store: { [key: string]: string } = {
|
@ -1,4 +1,4 @@
|
||||
import type { Context } from '../../context'
|
||||
import type { Context } from '@/context'
|
||||
import { getContentFromKVAsset, getKVFilePath } from '../../utils/cloudflare'
|
||||
|
||||
const EXTENSION = '.mustache'
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { poweredBy } from './powered-by'
|
||||
import { Hono } from '@/hono'
|
||||
import { poweredBy } from '@/middleware/powered-by'
|
||||
|
||||
describe('Powered by Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,9 +1,8 @@
|
||||
import type { Context } from '../../context'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
export const poweredBy = () => {
|
||||
return async (c: Context, next: Function) => {
|
||||
await next()
|
||||
// await c.res.headers.append('X-Powered-By', 'Hono')
|
||||
c.res.headers.append('X-Powered-By', 'Hono')
|
||||
}
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { prettyJSON } from './pretty-json'
|
||||
import { Hono } from '@/hono'
|
||||
import { prettyJSON } from '@/middleware/pretty-json'
|
||||
|
||||
describe('JSON pretty by Middleware', () => {
|
||||
const app = new Hono()
|
@ -1,4 +1,4 @@
|
||||
import type { Context } from '../../context'
|
||||
import type { Context } from '@/context'
|
||||
|
||||
type prettyOptions = {
|
||||
space: number
|
@ -1,5 +1,5 @@
|
||||
import { Hono } from '../../hono'
|
||||
import { serveStatic } from './serve-static'
|
||||
import { Hono } from '@/hono'
|
||||
import { serveStatic } from '@/middleware/serve-static'
|
||||
|
||||
// Mock
|
||||
const store: { [key: string]: string } = {
|
@ -1,6 +1,6 @@
|
||||
import type { Context } from '../../context'
|
||||
import { getContentFromKVAsset, getKVFilePath } from '../../utils/cloudflare'
|
||||
import { getMimeType } from '../../utils/mime'
|
||||
import type { Context } from '@/context'
|
||||
import { getContentFromKVAsset, getKVFilePath } from '@/utils/cloudflare'
|
||||
import { getMimeType } from '@/utils/mime'
|
||||
|
||||
type Options = {
|
||||
root: string
|
@ -1 +1 @@
|
||||
export { RegExpRouter } from './router'
|
||||
export { RegExpRouter } from '@/router/reg-exp-router/router'
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { RegExpRouter } from './router'
|
||||
import { METHOD_NAME_OF_ALL } from '../../router'
|
||||
import { RegExpRouter } from '@/router/reg-exp-router/router'
|
||||
import { METHOD_NAME_OF_ALL } from '@/router'
|
||||
|
||||
describe('Basic Usage', () => {
|
||||
const router = new RegExpRouter<string>()
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { Router, Result, METHOD_NAME_OF_ALL } from '../../router'
|
||||
import type { ParamMap } from './trie'
|
||||
import { Trie } from './trie'
|
||||
import { Router, Result, METHOD_NAME_OF_ALL } from '@/router'
|
||||
import type { ParamMap } from '@/router/reg-exp-router/trie'
|
||||
import { Trie } from '@/router/reg-exp-router/trie'
|
||||
|
||||
type Route<T> = [string, T]
|
||||
type HandlerData<T> = [T, ParamMap | null]
|
||||
|
@ -1,7 +1,7 @@
|
||||
import type { ParamMap, Context } from './node'
|
||||
import { Node } from './node'
|
||||
import type { ParamMap, Context } from '@/router/reg-exp-router/node'
|
||||
import { Node } from '@/router/reg-exp-router/node'
|
||||
|
||||
export type { ParamMap } from './node'
|
||||
export type { ParamMap } from '@/router/reg-exp-router/node'
|
||||
export type ReplacementMap = number[]
|
||||
|
||||
export class Trie {
|
||||
|
@ -1 +1 @@
|
||||
export { TrieRouter } from './router'
|
||||
export { TrieRouter } from '@/router/trie-router/router'
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Node } from './node'
|
||||
import { Node } from '@/router/trie-router/node'
|
||||
|
||||
describe('Root Node', () => {
|
||||
const node = new Node()
|
||||
|
@ -1,6 +1,6 @@
|
||||
import type { Pattern } from '../../utils/url'
|
||||
import { splitPath, getPattern } from '../../utils/url'
|
||||
import { Result, METHOD_NAME_OF_ALL } from '../../router'
|
||||
import type { Pattern } from '@/utils/url'
|
||||
import { splitPath, getPattern } from '@/utils/url'
|
||||
import { Result, METHOD_NAME_OF_ALL } from '@/router'
|
||||
|
||||
const noRoute = (): null => {
|
||||
return null
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { TrieRouter } from './router'
|
||||
import { TrieRouter } from '@/router/trie-router/router'
|
||||
|
||||
describe('Basic Usage', () => {
|
||||
const router = new TrieRouter<string>()
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { Router } from '../../router'
|
||||
import type { Result } from '../../router'
|
||||
import { Node } from './node'
|
||||
import { Router } from '@/router'
|
||||
import type { Result } from '@/router'
|
||||
import { Node } from '@/router/trie-router/node'
|
||||
|
||||
export class TrieRouter<T> extends Router<T> {
|
||||
node: Node<T>
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { parseBody } from './body'
|
||||
import { parseBody } from '@/utils/body'
|
||||
|
||||
describe('Parse Body Middleware', () => {
|
||||
it('should parse JSON', async () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { timingSafeEqual } from './buffer'
|
||||
import { timingSafeEqual } from '@/utils/buffer'
|
||||
import { SHA256 as sha256CryptoJS } from 'crypto-js'
|
||||
|
||||
describe('buffer', () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { sha256 } from './crypto'
|
||||
import { sha256 } from '@/utils/crypto'
|
||||
|
||||
export const equal = (a: ArrayBuffer, b: ArrayBuffer) => {
|
||||
if (a === b) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { getContentFromKVAsset, getKVFilePath } from './cloudflare'
|
||||
import { getContentFromKVAsset, getKVFilePath } from '@/utils/cloudflare'
|
||||
|
||||
// Mock
|
||||
const store: { [key: string]: string } = {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { sha256, sha1, decodeBase64, encodeBase64 } from './crypto'
|
||||
import { sha256, sha1, decodeBase64, encodeBase64 } from '@/utils/crypto'
|
||||
|
||||
describe('crypto', () => {
|
||||
it('sha256', async () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { getStatusText } from './http-status'
|
||||
import { getStatusText } from '@/utils/http-status'
|
||||
|
||||
describe('http-status utility', () => {
|
||||
it('getStatusText', () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { getMimeType } from './mime'
|
||||
import { getMimeType } from '@/utils/mime'
|
||||
|
||||
describe('mime', () => {
|
||||
it('getMimeType', () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { splitPath, getPattern, getPathFromURL, isAbsoluteURL, mergePath } from './url'
|
||||
import { splitPath, getPattern, getPathFromURL, isAbsoluteURL, mergePath } from '@/utils/url'
|
||||
|
||||
describe('url', () => {
|
||||
it('splitPath', () => {
|
||||
|
9
tsconfig.build.json
Normal file
9
tsconfig.build.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"include": [
|
||||
"src/**/*"
|
||||
],
|
||||
"exclude": [
|
||||
"src/**/*.test.ts"
|
||||
]
|
||||
}
|
@ -14,12 +14,16 @@
|
||||
"jest",
|
||||
"node",
|
||||
"@cloudflare/workers-types"
|
||||
]
|
||||
],
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"@/*": [
|
||||
"./src/*"
|
||||
]
|
||||
},
|
||||
},
|
||||
"include": [
|
||||
"src/**/*"
|
||||
],
|
||||
"exclude": [
|
||||
"src/**/*",
|
||||
"src/**/*.test.ts"
|
||||
]
|
||||
],
|
||||
}
|
69
yarn.lock
69
yarn.lock
@ -990,7 +990,7 @@ ansi-styles@^5.0.0:
|
||||
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-5.2.0.tgz#07449690ad45777d1924ac2abb2fc8895dba836b"
|
||||
integrity sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==
|
||||
|
||||
anymatch@^3.0.3:
|
||||
anymatch@^3.0.3, anymatch@~3.1.2:
|
||||
version "3.1.2"
|
||||
resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.2.tgz#c0557c096af32f106198f4f4e2a383537e378716"
|
||||
integrity sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==
|
||||
@ -1106,6 +1106,11 @@ balanced-match@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee"
|
||||
integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==
|
||||
|
||||
binary-extensions@^2.0.0:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d"
|
||||
integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==
|
||||
|
||||
brace-expansion@^1.1.7:
|
||||
version "1.1.11"
|
||||
resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd"
|
||||
@ -1114,7 +1119,7 @@ brace-expansion@^1.1.7:
|
||||
balanced-match "^1.0.0"
|
||||
concat-map "0.0.1"
|
||||
|
||||
braces@^3.0.1:
|
||||
braces@^3.0.1, braces@~3.0.2:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107"
|
||||
integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==
|
||||
@ -1213,6 +1218,21 @@ char-regex@^1.0.2:
|
||||
resolved "https://registry.yarnpkg.com/char-regex/-/char-regex-1.0.2.tgz#d744358226217f981ed58f479b1d6bcc29545dcf"
|
||||
integrity sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==
|
||||
|
||||
chokidar@^3.5.3:
|
||||
version "3.5.3"
|
||||
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd"
|
||||
integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==
|
||||
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"
|
||||
optionalDependencies:
|
||||
fsevents "~2.3.2"
|
||||
|
||||
ci-info@^3.2.0:
|
||||
version "3.3.0"
|
||||
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.3.0.tgz#b4ed1fb6818dea4803a55c623041f9165d2066b2"
|
||||
@ -1273,6 +1293,11 @@ combined-stream@^1.0.8:
|
||||
dependencies:
|
||||
delayed-stream "~1.0.0"
|
||||
|
||||
commander@^9.0.0:
|
||||
version "9.2.0"
|
||||
resolved "https://registry.yarnpkg.com/commander/-/commander-9.2.0.tgz#6e21014b2ed90d8b7c9647230d8b7a94a4a419a9"
|
||||
integrity sha512-e2i4wANQiSXgnrBlIatyHtP1odfUp0BbV5Y5nEGbxtIrStkEOAAzCUirvLBNXHLr7kwLvJl6V+4V3XV9x7Wd9w==
|
||||
|
||||
concat-map@0.0.1:
|
||||
version "0.0.1"
|
||||
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
|
||||
@ -1880,7 +1905,7 @@ fs.realpath@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f"
|
||||
integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8=
|
||||
|
||||
fsevents@^2.3.2:
|
||||
fsevents@^2.3.2, fsevents@~2.3.2:
|
||||
version "2.3.2"
|
||||
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a"
|
||||
integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==
|
||||
@ -1932,7 +1957,7 @@ get-symbol-description@^1.0.0:
|
||||
call-bind "^1.0.2"
|
||||
get-intrinsic "^1.1.1"
|
||||
|
||||
glob-parent@^5.1.2:
|
||||
glob-parent@^5.1.2, glob-parent@~5.1.2:
|
||||
version "5.1.2"
|
||||
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4"
|
||||
integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==
|
||||
@ -2130,6 +2155,13 @@ is-bigint@^1.0.1:
|
||||
dependencies:
|
||||
has-bigints "^1.0.1"
|
||||
|
||||
is-binary-path@~2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09"
|
||||
integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==
|
||||
dependencies:
|
||||
binary-extensions "^2.0.0"
|
||||
|
||||
is-boolean-object@^1.1.0:
|
||||
version "1.1.2"
|
||||
resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719"
|
||||
@ -2172,7 +2204,7 @@ is-generator-fn@^2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.1.0.tgz#7d140adc389aaf3011a8f2a2a4cfa6faadffb118"
|
||||
integrity sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==
|
||||
|
||||
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@^4.0.3:
|
||||
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@^4.0.3, is-glob@~4.0.1:
|
||||
version "4.0.3"
|
||||
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084"
|
||||
integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==
|
||||
@ -2976,6 +3008,11 @@ mustache@^4.2.0:
|
||||
resolved "https://registry.yarnpkg.com/mustache/-/mustache-4.2.0.tgz#e5892324d60a12ec9c2a73359edca52972bf6f64"
|
||||
integrity sha512-71ippSywq5Yb7/tVYyGbkBggbU8H3u5Rz56fH60jGFgr8uHwxs+aSKeqmluIVzM0m0kB7xQjKS6qPfd0b2ZoqQ==
|
||||
|
||||
mylas@^2.1.9:
|
||||
version "2.1.9"
|
||||
resolved "https://registry.yarnpkg.com/mylas/-/mylas-2.1.9.tgz#8329626f95c0ce522ca7d3c192eca6221d172cdc"
|
||||
integrity sha512-pa+cQvmhoM8zzgitPYZErmDt9EdTNVnXsH1XFjMeM4TyG4FFcgxrvK1+jwabVFwUOEDaSWuXBMjg43kqt/Ydlg==
|
||||
|
||||
natural-compare@^1.4.0:
|
||||
version "1.4.0"
|
||||
resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7"
|
||||
@ -2996,7 +3033,7 @@ node-releases@^2.0.1:
|
||||
resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.1.tgz#3d1d395f204f1f2f29a54358b9fb678765ad2fc5"
|
||||
integrity sha512-CqyzN6z7Q6aMeF/ktcMVTzhAHCEpf8SOarwpzpf8pNBY2k5/oM34UHldUwp8VKI7uxct2HxSRdJjBaZeESzcxA==
|
||||
|
||||
normalize-path@^3.0.0:
|
||||
normalize-path@^3.0.0, normalize-path@~3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65"
|
||||
integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==
|
||||
@ -3165,7 +3202,7 @@ picocolors@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c"
|
||||
integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==
|
||||
|
||||
picomatch@^2.0.4, picomatch@^2.2.3:
|
||||
picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.3:
|
||||
version "2.3.1"
|
||||
resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42"
|
||||
integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==
|
||||
@ -3244,6 +3281,13 @@ react-is@^17.0.1:
|
||||
resolved "https://registry.yarnpkg.com/react-is/-/react-is-17.0.2.tgz#e691d4a8e9c789365655539ab372762b0efb54f0"
|
||||
integrity sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w==
|
||||
|
||||
readdirp@~3.6.0:
|
||||
version "3.6.0"
|
||||
resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7"
|
||||
integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==
|
||||
dependencies:
|
||||
picomatch "^2.2.1"
|
||||
|
||||
regexpp@^3.0.0, regexpp@^3.1.0, regexpp@^3.2.0:
|
||||
version "3.2.0"
|
||||
resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2"
|
||||
@ -3634,6 +3678,17 @@ ts-jest@^27.1.2:
|
||||
semver "7.x"
|
||||
yargs-parser "20.x"
|
||||
|
||||
tsc-alias@^1.6.6:
|
||||
version "1.6.6"
|
||||
resolved "https://registry.yarnpkg.com/tsc-alias/-/tsc-alias-1.6.6.tgz#1bdda705efa6251b9a62593e8ed4b0285c20803b"
|
||||
integrity sha512-wQuIKleaPuQKpTwrzFb1gTOd3ZsB5GqIK+aPyh1okOLfYYNsMyxIypIYctQnSxiJ243iRxLdvNlboZOTEdK1MQ==
|
||||
dependencies:
|
||||
chokidar "^3.5.3"
|
||||
commander "^9.0.0"
|
||||
globby "^11.0.4"
|
||||
mylas "^2.1.9"
|
||||
normalize-path "^3.0.0"
|
||||
|
||||
tsconfig-paths@^3.12.0, tsconfig-paths@^3.9.0:
|
||||
version "3.12.0"
|
||||
resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.12.0.tgz#19769aca6ee8f6a1a341e38c8fa45dd9fb18899b"
|
||||
|
Loading…
Reference in New Issue
Block a user