From eab36f97359b74354af19c25fa9c4e8971ec0e3f Mon Sep 17 00:00:00 2001 From: Falldot Date: Sun, 14 Nov 2021 03:51:12 +1100 Subject: [PATCH] new api --- .gitignore | 18 + LICENSE | 21 + README.md | 109 ++ cmd/build/build.go | 25 + cmd/devserver/devserver.go | 31 + esbuild-dev-server.go | 64 + example/esbuild.config.go | 25 + example/esbuild.config.js | 19 + example/package.json | 17 + example/src/index.js | 3 + example/yarn-error.log | 211 ++ go.mod | 11 + go.sum | 15 + internal/api/api.go | 66 + internal/api/handlers.go | 41 + internal/api/methods.go | 9 + internal/watcher/watcher.go | 58 + internal/ws/client.go | 100 + internal/ws/hub.go | 56 + internal/ws/script.go | 101 + lib/.eslintignore | 2 + lib/.eslintrc.js | 13 + lib/package.json | 45 + lib/src/esbuild-dev-server.ts | 106 ++ lib/tsconfig.json | 14 + lib/yarn.lock | 1689 +++++++++++++++++ makefile | 71 + npm/esbuild-dev-server-darwin-arm64/README.md | 3 + .../package.json | 37 + npm/esbuild-dev-server-darwin-x64/README.md | 3 + .../package.json | 37 + npm/esbuild-dev-server-linux-arm/README.md | 3 + npm/esbuild-dev-server-linux-arm/package.json | 37 + npm/esbuild-dev-server-linux-arm64/README.md | 3 + .../package.json | 37 + npm/esbuild-dev-server-linux-x32/README.md | 3 + npm/esbuild-dev-server-linux-x32/package.json | 37 + npm/esbuild-dev-server-linux-x64/README.md | 3 + npm/esbuild-dev-server-linux-x64/package.json | 37 + npm/esbuild-dev-server-win32-arm64/README.md | 3 + .../package.json | 37 + npm/esbuild-dev-server-win32-x32/README.md | 3 + npm/esbuild-dev-server-win32-x32/package.json | 37 + npm/esbuild-dev-server-win32-x64/README.md | 3 + npm/esbuild-dev-server-win32-x64/package.json | 37 + npm/esbuild-dev-server/README.md | 109 ++ npm/esbuild-dev-server/package.json | 44 + 47 files changed, 3453 insertions(+) create mode 100644 .gitignore create mode 100644 LICENSE create mode 100644 README.md create mode 100644 cmd/build/build.go create mode 100644 cmd/devserver/devserver.go create mode 100644 esbuild-dev-server.go create mode 100644 example/esbuild.config.go create mode 100644 example/esbuild.config.js create mode 100644 example/package.json create mode 100644 example/src/index.js create mode 100644 example/yarn-error.log create mode 100644 go.mod create mode 100644 go.sum create mode 100644 internal/api/api.go create mode 100644 internal/api/handlers.go create mode 100644 internal/api/methods.go create mode 100644 internal/watcher/watcher.go create mode 100644 internal/ws/client.go create mode 100644 internal/ws/hub.go create mode 100644 internal/ws/script.go create mode 100644 lib/.eslintignore create mode 100644 lib/.eslintrc.js create mode 100644 lib/package.json create mode 100644 lib/src/esbuild-dev-server.ts create mode 100644 lib/tsconfig.json create mode 100644 lib/yarn.lock create mode 100644 makefile create mode 100644 npm/esbuild-dev-server-darwin-arm64/README.md create mode 100644 npm/esbuild-dev-server-darwin-arm64/package.json create mode 100644 npm/esbuild-dev-server-darwin-x64/README.md create mode 100644 npm/esbuild-dev-server-darwin-x64/package.json create mode 100644 npm/esbuild-dev-server-linux-arm/README.md create mode 100644 npm/esbuild-dev-server-linux-arm/package.json create mode 100644 npm/esbuild-dev-server-linux-arm64/README.md create mode 100644 npm/esbuild-dev-server-linux-arm64/package.json create mode 100644 npm/esbuild-dev-server-linux-x32/README.md create mode 100644 npm/esbuild-dev-server-linux-x32/package.json create mode 100644 npm/esbuild-dev-server-linux-x64/README.md create mode 100644 npm/esbuild-dev-server-linux-x64/package.json create mode 100644 npm/esbuild-dev-server-win32-arm64/README.md create mode 100644 npm/esbuild-dev-server-win32-arm64/package.json create mode 100644 npm/esbuild-dev-server-win32-x32/README.md create mode 100644 npm/esbuild-dev-server-win32-x32/package.json create mode 100644 npm/esbuild-dev-server-win32-x64/README.md create mode 100644 npm/esbuild-dev-server-win32-x64/package.json create mode 100644 npm/esbuild-dev-server/README.md create mode 100644 npm/esbuild-dev-server/package.json diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..019ae81 --- /dev/null +++ b/.gitignore @@ -0,0 +1,18 @@ +dist +example/public/js +example/node_modules +example/yarn.lock +lib/node_modules + +npm/lib/ +npm/esbuild-dev-server/lib/ +npm/esbuild-dev-server-darwin-x64/devserver +npm/esbuild-dev-server-darwin-arm64/devserver +npm/esbuild-dev-server-linux-x32/devserver +npm/esbuild-dev-server-linux-x64/devserver +npm/esbuild-dev-server-linux-arm/devserver +npm/esbuild-dev-server-linux-arm64/devserver +npm/esbuild-dev-server-win32-x32/devserver.exe +npm/esbuild-dev-server-win32-x64/devserver.exe +npm/esbuild-dev-server-win32-arm64/devserver.exe + diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..c15dc9e --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Vladislav Fedotov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..da5aa65 --- /dev/null +++ b/README.md @@ -0,0 +1,109 @@ +# esbuild-dev-server + +This plugin allows you to start a local server with hot reloading for [Esbuild](https://esbuild.github.io/) + +More community [plugins](https://github.com/esbuild/community-plugins) + +## Installation +`npm` +``` +npm i esbuild-dev-server -D +``` +`yarn` +``` +yarn add esbuild-dev-server -D +``` +`go` +``` +go get github.com/Falldot/esbuild-dev-server +``` +## Configuration + +- `options.port`, `string`: local server start port. +- `options.index`, `string`: path to index html file. +- `options.staticDir`, `string`: path to static files (js, css, img ...). +- `options.watchDir`, `string`: path to working directory. +- `options.onBeforeRebuild`, `() => void`: event before rebuild. +- `options.onAfterRebuild`, `() => void`: event after rebuild. + +## How to use? +### Node.js +`esbuild.config.js` +```js +const {build} = require("esbuild") +const esBuildDevServer = require("esbuild-dev-server") + +esBuildDevServer.start( + build({ + entryPoints: ["src/index.js"], + outdir: "dist", + incremental: true, + // and more options ... + }), + { + port: "8080", // optional, default: 8080 + watchDir: "src", // optional, default: "src" + index: "dist/index.html", // optional + staticDir: "dist", // optional + onBeforeRebuild: {}, // optional + onAfterRebuild: {}, // optional + } +) +``` +`package.json` +```json +"scripts": { + "dev": "node esbuild.config.js", +}, +``` +`dist/index.html` +```html + + + + + + + Document + + +
+ + + +``` +### Golang +`esbuild.config.go` +```go +package main + +import ( + devserver "github.com/Falldot/esbuild-dev-server" + "github.com/evanw/esbuild/pkg/api" +) + +func main() { + devserver.Start( + api.Build(api.BuildOptions{ + EntryPoints: []string{"src/index.js"}, + Outdir: "dist", + Incremental: true, + // and more options ... + }), + devserver.Options{ + Port: "8080", // optional, default: 8080 + WatchDir: "src", // optional, default: "src" + Index: "dist/index.html", // optional + StaticDir: "dist", // optional + OnBeforeRebuild: func() {}, // optional + OnAfterRebuild: func() {}, // optional + }, + ) +} +``` +`package.json` +```json +"scripts": { + "dev": "go esbuild.config.go", +}, +``` \ No newline at end of file diff --git a/cmd/build/build.go b/cmd/build/build.go new file mode 100644 index 0000000..ea894a2 --- /dev/null +++ b/cmd/build/build.go @@ -0,0 +1,25 @@ +package main + +import ( + "log" + + "github.com/evanw/esbuild/pkg/api" +) + +func main() { + result := api.Build(api.BuildOptions{ + EntryPoints: []string{"lib/src/esbuild-dev-server.ts"}, + Bundle: true, + Platform: api.PlatformNode, + Engines: []api.Engine{ + {api.EngineNode, "14.18"}, + }, + Tsconfig: "lib/tsconfig.json", + Write: true, + Outdir: "npm/esbuild-dev-server/lib", + }) + + if len(result.Errors) > 0 { + log.Fatalln(result.Errors) + } +} diff --git a/cmd/devserver/devserver.go b/cmd/devserver/devserver.go new file mode 100644 index 0000000..1079119 --- /dev/null +++ b/cmd/devserver/devserver.go @@ -0,0 +1,31 @@ +package main + +import ( + "flag" + "fmt" + "log" + + "github.com/Falldot/esbuild-dev-server/internal/api" +) + +func main() { + + port := flag.String("p", "", "local server start port") + idnex := flag.String("i", "", "path to index html file") + staticDir := flag.String("s", "", "path to static files (js, css, img ...)") + watchDir := flag.String("w", "", "path to working directory") + flag.Parse() + + server := api.DevServer{ + Port: *port, + Index: *idnex, + StaticDir: *staticDir, + WatchDir: *watchDir, + OnReload: func() { + fmt.Print("Reload") + }, + } + if err := server.Start(); err != nil { + log.Fatalln(err) + } +} diff --git a/esbuild-dev-server.go b/esbuild-dev-server.go new file mode 100644 index 0000000..4767ec8 --- /dev/null +++ b/esbuild-dev-server.go @@ -0,0 +1,64 @@ +package devserver + +import ( + "log" + + plugin "github.com/Falldot/esbuild-dev-server/internal/api" + "github.com/evanw/esbuild/pkg/api" +) + +type Options struct { + Port string + Index string + StaticDir string + WatchDir string + OnBeforeRebuild func() + OnAfterRebuild func() +} + +func Start(build api.BuildResult, options Options) { + if !errorHandler(build.Errors, nil) { + log.Fatalln("esbuild error!") + } + + var server plugin.DevServer + server = plugin.DevServer{ + Port: options.Port, + Index: options.Index, + StaticDir: options.StaticDir, + WatchDir: options.WatchDir, + OnReload: func() { + if options.OnBeforeRebuild != nil { + options.OnBeforeRebuild() + } + result := build.Rebuild() + if errorHandler(result.Errors, server.SendError) { + server.SendReload() + } + if options.OnAfterRebuild != nil { + options.OnAfterRebuild() + } + }, + } + + if err := server.Start(); err != nil { + log.Fatalln(err) + } +} + +func errorHandler(errors []api.Message, callback func(string)) bool { + if len(errors) > 0 { + str := api.FormatMessages(errors, api.FormatMessagesOptions{ + Kind: api.ErrorMessage, + Color: true, + }) + for _, err := range str { + log.Println(err) + if callback != nil { + callback(err) + } + } + return false + } + return true +} diff --git a/example/esbuild.config.go b/example/esbuild.config.go new file mode 100644 index 0000000..4faf8d9 --- /dev/null +++ b/example/esbuild.config.go @@ -0,0 +1,25 @@ +package main + +import ( + devserver "github.com/Falldot/esbuild-dev-server" + "github.com/evanw/esbuild/pkg/api" +) + +func main() { + devserver.Start( + api.Build(api.BuildOptions{ + EntryPoints: []string{"src/index.js"}, + Outdir: "dist", + Incremental: true, + // and more options ... + }), + devserver.Options{ + Port: "8080", // optional, default: 8080 + WatchDir: "src", // optional, default: "src" + Index: "dist/index.html", // optional + StaticDir: "dist", // optional + OnBeforeRebuild: func() {}, // optional + OnAfterRebuild: func() {}, // optional + }, + ) +} diff --git a/example/esbuild.config.js b/example/esbuild.config.js new file mode 100644 index 0000000..064bbb8 --- /dev/null +++ b/example/esbuild.config.js @@ -0,0 +1,19 @@ +const {build} = require("esbuild") +const esBuildDevServer = require("esbuild-dev-server") + +esBuildDevServer.start( + build({ + entryPoints: ["src/index.js"], + outdir: "dist/js", + incremental: true, + // and more options ... + }), + { + port: "8080", // optional, default: 8080 + watchDir: "src", // optional, default: "src" + index: "dist/index.html", // optional + staticDir: "dist", // optional + onBeforeRebuild: {}, // optional + onAfterRebuild: {}, // optional + } +) \ No newline at end of file diff --git a/example/package.json b/example/package.json new file mode 100644 index 0000000..1ba4fbb --- /dev/null +++ b/example/package.json @@ -0,0 +1,17 @@ +{ + "name": "example", + "version": "1.0.0", + "main": "index.js", + "author": "Vladislav Fedotov", + "license": "MIT", + "private": true, + "scripts": { + "js-start": "node esbuild.config.js", + "go-start": "go run esbuild.config.go" + }, + "devDependencies": { + "esbuild": "^0.13.2", + "esbuild-dev-server": "../npm/esbuild-dev-server", + "esbuild-dev-server-win32-x64": "../npm/esbuild-dev-server-win32-x64" + } +} diff --git a/example/src/index.js b/example/src/index.js new file mode 100644 index 0000000..b48c15b --- /dev/null +++ b/example/src/index.js @@ -0,0 +1,3 @@ +console.log("Hello world!dsa!!!"); + +console.log("hi!!!"); \ No newline at end of file diff --git a/example/yarn-error.log b/example/yarn-error.log new file mode 100644 index 0000000..1590b04 --- /dev/null +++ b/example/yarn-error.log @@ -0,0 +1,211 @@ +Arguments: + C:\Program Files\nodejs\node.exe C:\Users\surve\AppData\Roaming\npm\node_modules\yarn\bin\yarn.js add -D ../npm/esbuild-dev-server + +PATH: + C:\Python39\Scripts\;C:\Python39\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\iCLS\;C:\Program Files\Intel\Intel(R) Management Engine Components\iCLS\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\ProgramData\chocolatey\bin;C:\Program Files\Git\cmd;C:\Program Files\nodejs\;C:\Program Files\CMake\bin;C:\Program Files\Microsoft VS Code\bin;C:\Program Files\msys64\mingw64\x86_64-w64-mingw32\bin;C:\Program Files\msys64\mingw64\bin;C:\Program Files\dotnet\;C:\OpenServer\composer;C:\OpenServer\modules\php\PHP_7.3;C:\Program Files (x86)\dotnet\;C:\Program Files\Go\bin;C:\Users\surve\AppData\Local\Microsoft\WindowsApps;C:\Users\surve\AppData\Roaming\npm;C:\Users\surve\AppData\Roaming\Composer\vendor\bin;C:\Users\surve\.dotnet\tools;C:\Program Files\JetBrains\PhpStorm 2021.2.3\bin;C:\Users\surve\go\bin + +Yarn version: + 1.22.11 + +Node version: + 16.10.0 + +Platform: + win32 x64 + +Trace: + SyntaxError: D:\github.com\Falldot\esbuild-dev-server\example\package.json: Unexpected token } in JSON at position 340 + at JSON.parse () + at C:\Users\surve\AppData\Roaming\npm\node_modules\yarn\lib\cli.js:1625:59 + at Generator.next () + at step (C:\Users\surve\AppData\Roaming\npm\node_modules\yarn\lib\cli.js:310:30) + at C:\Users\surve\AppData\Roaming\npm\node_modules\yarn\lib\cli.js:321:13 + +npm manifest: + { + "name": "example", + "version": "1.0.0", + "main": "index.js", + "author": "Vladislav Fedotov", + "license": "MIT", + "private": true, + "scripts": { + "start": "node build/build.js", + "gostart": "go run build/build.go" + }, + "devDependencies": { + "esbuild": "^0.13.2", + "esbuild-dev-server": "../npm/esbuild-dev-server", + } + } + +yarn manifest: + No manifest + +Lockfile: + # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. + # yarn lockfile v1 + + + esbuild-android-arm64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.13.3.tgz#ef734c76eeff42e8c53acdffe901da090164a890" + integrity sha512-jc9E8vGTHkzb0Vwl74H8liANV9BWsqtzLHaKvcsRgf1M+aVCBSF0gUheduAKfDsbDMT0judeMLhwBP34EUesTA== + + esbuild-darwin-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.13.3.tgz#35f29376b7451add79f0640980683ef923365385" + integrity sha512-8bG3Zq+ZNuLlIJebOO2+weI7P2LVf33sOzaUfHj8MuJ+1Ixe4KtQxfYp7qhFnP6xP2ToJaYHxGUfLeiUCEz9hw== + + esbuild-darwin-arm64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.13.3.tgz#530a1326e7d18d62c9a54b6dce70f2b77ed50eec" + integrity sha512-5E81eImYtTgh8pY7Gq4WQHhWkR/LvYadUXmuYeZBiP+3ADZJZcG60UFceZrjqNPaFOWKr/xmh4aNocwagEubcA== + + esbuild-dev-server-darwin-arm64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-darwin-arm64/-/esbuild-dev-server-darwin-arm64-0.2.1.tgz#fd3e0e00b1e288b54190fb567aac9f6b994c6535" + integrity sha512-0/EdL0Ok4WuMs12wjDeUuIAbwwmokoCg10k4tBr0Bkdvv/OC5DcZFCfYWCcNOS30eESsU/LTx8rWLwGgLIQMog== + + esbuild-dev-server-darwin-x64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-darwin-x64/-/esbuild-dev-server-darwin-x64-0.2.1.tgz#42b69ef39a35ceeefc3750cd5344aac3b871a2e8" + integrity sha512-UHnXO9OmnzRZvN2sNYEJjf2i+08w/Yu3hxJqXZCZBgYmyla6ZU+gSAd074uNwovNipxeUZQfnk6mNtHNZBPQrQ== + + esbuild-dev-server-linux-arm64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-linux-arm64/-/esbuild-dev-server-linux-arm64-0.2.1.tgz#b5a79843ffb8b57051481a9f2637b722a7abfa24" + integrity sha512-NmlQm5UDM3t8h3hjHhrfKlc4Jvy6pRCiSrCza9stEp52vC+B3+1TBCiyUJSvkETaf/Yufd8OfDH0I1xyvUSgVQ== + + esbuild-dev-server-linux-arm@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-linux-arm/-/esbuild-dev-server-linux-arm-0.2.1.tgz#92d2ada9e4b410ac60251b393ba061a938051bf0" + integrity sha512-lIZNFlnXtMoo0Sz4DXPAKKoI0ps1DaOUfYQdSYYZ2wWBhknP32i3ub5V5A8IDB5JXdXHwsVhIYwo4yk9qrqOFg== + + esbuild-dev-server-linux-x32@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-linux-x32/-/esbuild-dev-server-linux-x32-0.2.1.tgz#7a27ebe835b26bf8283273ebe6e7a1fe3aed7e53" + integrity sha512-7YLlrxYbCXl3JL1xuavfZLL3LpzywQYR3UzpFlaFVYC/sLb7gxE4IEuLsb8lNuWiuRQfSzIeh7VXFX/moqWDtQ== + + esbuild-dev-server-linux-x64@../npm/esbuild-dev-server-linux-x64: + version "0.2.1" + + esbuild-dev-server-linux-x64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-linux-x64/-/esbuild-dev-server-linux-x64-0.2.1.tgz#7fe492a7dd3b99310de6f65bf104ce20a4f7e66a" + integrity sha512-9rQycJrlfnlu1Rc2iARwlqDiDWsJyQvuKhRNmwcPI2SCC0HLww3ypqx3KO1rbqukZzJckit60a8buG7zkdxXww== + + esbuild-dev-server-win32-arm64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-win32-arm64/-/esbuild-dev-server-win32-arm64-0.2.1.tgz#e99b8138be8820851d3f16e27852c110aba133f2" + integrity sha512-rXF95GzbTo4j0vm/pbJFtH608E9KocGwnoSfFUTFI9AW2JWfIaMRI+TrXe/ljNeuEkbB0A+WmrJXmhof9RybzQ== + + esbuild-dev-server-win32-x32@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-win32-x32/-/esbuild-dev-server-win32-x32-0.2.1.tgz#a2032d053d371a7efa55678056e271116cb3f76a" + integrity sha512-MHS1d5X9kjDiJvDWIDIzYuto7uqXEpe+cs+uynI2VODVYARR7ezgQGrxQf/eeXLxRj1MMHtsVO92GE/UQeS+Ag== + + esbuild-dev-server-win32-x64@0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/esbuild-dev-server-win32-x64/-/esbuild-dev-server-win32-x64-0.2.1.tgz#d337e45a8cf3a4ecd503e6e31cf3c336884a1d83" + integrity sha512-MOVWLUIIDcONepXbYKDLsDAE2OuUYVQ4YD3/eKKBhOvWWu0SG6XYoboDjwUyj7cN7WOjpAp+v0fie4KyGXtIJg== + + esbuild-dev-server@../npm/esbuild-dev-server: + version "0.2.1" + optionalDependencies: + esbuild-dev-server-darwin-arm64 "0.2.1" + esbuild-dev-server-darwin-x64 "0.2.1" + esbuild-dev-server-linux-arm "0.2.1" + esbuild-dev-server-linux-arm64 "0.2.1" + esbuild-dev-server-linux-x32 "0.2.1" + esbuild-dev-server-linux-x64 "0.2.1" + esbuild-dev-server-win32-arm64 "0.2.1" + esbuild-dev-server-win32-x32 "0.2.1" + esbuild-dev-server-win32-x64 "0.2.1" + + esbuild-freebsd-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.13.3.tgz#ce2896ac362e06eb82ca5dec06b2568901eb5afc" + integrity sha512-ou+f91KkTGexi8HvF/BdtsITL6plbciQfZGys7QX6/QEwyE96PmL5KnU6ZQwoU7E99Ts6Sc9bUDq8HXJubKtBA== + + esbuild-freebsd-arm64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.13.3.tgz#a20454f99e060bea4e465d131556a9f0533f403f" + integrity sha512-F1zV7nySjHswJuvIgjkiG5liZ63MeazDGXGKViTCeegjZ71sAhOChcaGhKcu6vq9+vqZxlfEi1fmXlx6Pc3coQ== + + esbuild-linux-32@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.13.3.tgz#ad56f18208ecf007cd9ab16cd39626ca0312b8ee" + integrity sha512-mHHc2v6uLrHH4zaaq5RB/5IWzgimEJ1HGldzf1qtGI513KZWfH0HRRQ8p1di4notJgBn7tDzWQ1f34ZHy69viQ== + + esbuild-linux-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.13.3.tgz#be1eabadf68d153897ed887678f7496d3949810f" + integrity sha512-FJ1De2O89mrOuqtaEXu41qIYJU6R41F+OA6vheNwcAQcX8fu0aiA13FJeLABq29BYJuTVgRj3cyC8q+tz19/dQ== + + esbuild-linux-arm64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.13.3.tgz#329348bb4a19cfb5e9046cc5d97ba5017d8f74ad" + integrity sha512-Cauhr45KSo+wRUojs+1qfycQqQCAXTOvsWvkZ6xmEMAXLAm+f8RQGDQeP8CAf8Yeelnegcn6UNdvzdzLHhWDFg== + + esbuild-linux-arm@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.13.3.tgz#b3b3167c9d5d3038894fbc75b194a4fbe93eaf09" + integrity sha512-9BJNRtLwBh3OP22cln9g3AJdbAQUcjRHqA4BScx9k4RZpGqPokFr548zpeplxWhcwrIjT8qPebwH9CrRVy8Bsw== + + esbuild-linux-mips64le@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.13.3.tgz#ea1687f28ea2c85399ecc2fe23a48ab343b7b35d" + integrity sha512-YVzJUGCncuuLm2boYyVeuMFsak4ZAhdiBwi0xNDZCC8sy+tS6Boe2mzcrD2uubv5JKAUOrpN186S1DtU4WgBgw== + + esbuild-linux-ppc64le@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.13.3.tgz#a462cf42eae3d7fc29a9f277679f5adee70afa67" + integrity sha512-GU6CqqKtJEoyxC2QWHiJtmuOz9wc/jMv8ZloK2WwiGY5yMvAmM3PI103Dj7xcjebNTHBqITTUw/aigY1wx5A3w== + + esbuild-openbsd-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.13.3.tgz#0cb15bd86d20eb19cb548b530f1a533197532cf9" + integrity sha512-HVpkgpn4BQt4BPDAjTOpeMub6mzNWw6Y3gaLQJrpbO24pws6ZwYkY24OI3/Uo3LDCbH6856MM81JxECt92OWjA== + + esbuild-sunos-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.13.3.tgz#53a941241f881010969cc8f1acb1ada49c4cd3c2" + integrity sha512-XncBVOtnEfUbPV4CaiFBxh38ychnBfwCxuTm9iAqcHzIwkmeNRN5qMzDyfE1jyfJje+Bbt6AvIfz6SdYt8/UEQ== + + esbuild-windows-32@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.13.3.tgz#265dc0d0cdb5374685a851c584857055e12865a4" + integrity sha512-ZlgDz7d1nk8wQACi+z8IDzNZVUlN9iprAme+1YSTsfFDlkyI8jeaGWPk9EQFNY7rJzsLVYm6eZ2mhPioc7uT5A== + + esbuild-windows-64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.13.3.tgz#ae710c0629ec8c39c5ef1f69e86ed5592bb4128f" + integrity sha512-YX7KvRez3TR+GudlQm9tND/ssj2FsF9vb8ZWzAoZOLxpPzE3y+3SFJNrfDzzQKPzJ0Pnh9KBP4gsaMwJjKHDhw== + + esbuild-windows-arm64@0.13.3: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.13.3.tgz#a236199a26b1205573dcb571f966189326a4c953" + integrity sha512-nP7H0Y2a6OJd3Qi1Q8sehhyP4x4JoXK4S5y6FzH2vgaJgiyEurzFxjUufGdMaw+RxtxiwD/uRndUgwaZ2JD8lg== + + esbuild@^0.13.2: + version "0.13.3" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.13.3.tgz#cc9fc347fc81ff6440cdd1fdb9fe65c02eddcc97" + integrity sha512-98xovMLKnyhv3gcReUuAEi5Ig1rK6SIgvsJuBIcfwzqGSEHsV8UJjMlmkhHoHMf9XZybMpE9Zax8AA8f7i2hlQ== + optionalDependencies: + esbuild-android-arm64 "0.13.3" + esbuild-darwin-64 "0.13.3" + esbuild-darwin-arm64 "0.13.3" + esbuild-freebsd-64 "0.13.3" + esbuild-freebsd-arm64 "0.13.3" + esbuild-linux-32 "0.13.3" + esbuild-linux-64 "0.13.3" + esbuild-linux-arm "0.13.3" + esbuild-linux-arm64 "0.13.3" + esbuild-linux-mips64le "0.13.3" + esbuild-linux-ppc64le "0.13.3" + esbuild-openbsd-64 "0.13.3" + esbuild-sunos-64 "0.13.3" + esbuild-windows-32 "0.13.3" + esbuild-windows-64 "0.13.3" + esbuild-windows-arm64 "0.13.3" diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..952ff00 --- /dev/null +++ b/go.mod @@ -0,0 +1,11 @@ +module github.com/Falldot/esbuild-dev-server + +go 1.17 + +require ( + github.com/evanw/esbuild v0.13.13 + github.com/fsnotify/fsnotify v1.5.1 + github.com/gorilla/websocket v1.4.2 +) + +require golang.org/x/sys v0.0.0-20211109184856-51b60fd695b3 // indirect diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..f34e1ca --- /dev/null +++ b/go.sum @@ -0,0 +1,15 @@ +github.com/evanw/esbuild v0.13.3 h1:o3oziz5XUWVmik/McYDYsGJHiSpDr+MK5AZgZlrbQSE= +github.com/evanw/esbuild v0.13.3/go.mod h1:GG+zjdi59yh3ehDn4ZWfPcATxjPDUH53iU4ZJbp7dkY= +github.com/evanw/esbuild v0.13.13 h1:KfO9yqcgsiRIPj8j0pgzxW28xFz2Jjg3RhNYOmqwclk= +github.com/evanw/esbuild v0.13.13/go.mod h1:GG+zjdi59yh3ehDn4ZWfPcATxjPDUH53iU4ZJbp7dkY= +github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI= +github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU= +github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= +github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c h1:F1jZWGFhYfh0Ci55sIpILtKKK8p3i2/krTr0H1rg74I= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6 h1:foEbQz/B0Oz6YIqu/69kfXPYeFQAuuMYFkjaqXzl5Wo= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211109184856-51b60fd695b3 h1:T6tyxxvHMj2L1R2kZg0uNMpS8ZhB9lRa9XRGTCSA65w= +golang.org/x/sys v0.0.0-20211109184856-51b60fd695b3/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= diff --git a/internal/api/api.go b/internal/api/api.go new file mode 100644 index 0000000..48f4a54 --- /dev/null +++ b/internal/api/api.go @@ -0,0 +1,66 @@ +package api + +import ( + "log" + "net/http" + "os" + + "github.com/Falldot/esbuild-dev-server/internal/watcher" + "github.com/Falldot/esbuild-dev-server/internal/ws" +) + +type DevServer struct { + Port string + Index string + StaticDir string + WatchDir string + OnReload func() + + IsStart bool + + hub *ws.Hub +} + +func (s *DevServer) Start() error { + log.Println("Starting dev server.") + if s.Port == "" { + s.Port = "8080" + } + s.Port = ":" + s.Port + + s.hub = ws.NewHub() + go s.hub.Run() + + if s.StaticDir != "" { + files, err := os.ReadDir(s.StaticDir) + if err != nil { + return err + } + for _, file := range files { + if file.IsDir() { + path := "/" + file.Name() + "/" + http.Handle(path, http.StripPrefix(path, http.FileServer(http.Dir(s.StaticDir+path)))) + } + } + } + + if s.Index == "" { + http.HandleFunc("/", s.ViewDefault) + } else { + http.HandleFunc("/", s.View) + } + http.HandleFunc("/reload", s.Reload) + http.HandleFunc("/connect", s.Connect) + http.HandleFunc("/error", s.Error) + + if s.WatchDir == "" { + s.WatchDir = "src" + } + go watcher.Watch(s.WatchDir, s.OnReload) + + log.Println("Dev server started.") + log.Println("http://localhost" + s.Port + "/") + + s.IsStart = true + return http.ListenAndServe(s.Port, nil) +} diff --git a/internal/api/handlers.go b/internal/api/handlers.go new file mode 100644 index 0000000..be96b62 --- /dev/null +++ b/internal/api/handlers.go @@ -0,0 +1,41 @@ +package api + +import ( + "io" + "log" + "net/http" + + "github.com/Falldot/esbuild-dev-server/internal/ws" +) + +func (s *DevServer) Connect(w http.ResponseWriter, r *http.Request) { + ws.NewClient(s.hub, w, r) +} + +func (s *DevServer) Reload(w http.ResponseWriter, r *http.Request) { + s.hub.SendReload() +} + +func (s *DevServer) Error(w http.ResponseWriter, r *http.Request) { + message, err := io.ReadAll(r.Body) + if err != nil { + log.Println(err) + } + s.hub.SendErrorBytes(message) +} + +func (s *DevServer) View(w http.ResponseWriter, r *http.Request) { + tmpl, err := ws.AddHotReloadScript(s.Index, s.Port) + if err != nil { + log.Println(err) + } + tmpl.Execute(w, nil) +} + +func (s *DevServer) ViewDefault(w http.ResponseWriter, r *http.Request) { + tmpl, err := ws.GetDefaultHtmlFile(s.Port) + if err != nil { + log.Println(err) + } + tmpl.Execute(w, nil) +} diff --git a/internal/api/methods.go b/internal/api/methods.go new file mode 100644 index 0000000..f3049ae --- /dev/null +++ b/internal/api/methods.go @@ -0,0 +1,9 @@ +package api + +func (s *DevServer) SendReload() { + s.hub.SendReload() +} + +func (s *DevServer) SendError(message string) { + s.hub.SendError(message) +} diff --git a/internal/watcher/watcher.go b/internal/watcher/watcher.go new file mode 100644 index 0000000..f587a41 --- /dev/null +++ b/internal/watcher/watcher.go @@ -0,0 +1,58 @@ +package watcher + +import ( + "io/fs" + "log" + "path/filepath" + + "github.com/fsnotify/fsnotify" +) + +func Watch(dir string, action func()) { + watcher, err := fsnotify.NewWatcher() + if err != nil { + log.Fatal(err) + } + defer watcher.Close() + + done := make(chan bool) + go func() { + for { + select { + case event, ok := <-watcher.Events: + if !ok { + return + } + if event.Op&fsnotify.Write == fsnotify.Write || event.Op&fsnotify.Remove == fsnotify.Remove || event.Op&fsnotify.Rename == fsnotify.Rename { + action() + } + if event.Op&fsnotify.Create == fsnotify.Create { + walk(event.Name, watcher) + } + case err, ok := <-watcher.Errors: + if !ok { + return + } + log.Println("error:", err) + } + } + }() + + walk(dir, watcher) + + <-done +} + +func walk(dir string, watcher *fsnotify.Watcher) { + if err := filepath.WalkDir(dir, func(path string, d fs.DirEntry, err error) error { + if err != nil { + return err + } + if d.IsDir() { + return watcher.Add(path) + } + return nil + }); err != nil { + log.Fatal(err) + } +} diff --git a/internal/ws/client.go b/internal/ws/client.go new file mode 100644 index 0000000..09024ca --- /dev/null +++ b/internal/ws/client.go @@ -0,0 +1,100 @@ +package ws + +import ( + "log" + "net/http" + "time" + + "github.com/gorilla/websocket" +) + +const ( + writeWait = 10 * time.Second + pongWait = 60 * time.Second + pingPeriod = (pongWait * 9) / 10 +) + +type Client struct { + hub *Hub + conn *websocket.Conn + send chan []byte +} + +var upgrader = websocket.Upgrader{ + ReadBufferSize: 1024, + WriteBufferSize: 1024, + CheckOrigin: func(r *http.Request) bool { + return true + }, +} + +func NewClient(hub *Hub, w http.ResponseWriter, r *http.Request) { + conn, err := upgrader.Upgrade(w, r, nil) + if err != nil { + log.Println(err) + return + } + client := &Client{hub: hub, conn: conn, send: make(chan []byte, 256)} + client.hub.register <- client + go client.writePump() + client.readPump() +} + +func (c *Client) readPump() { + defer func() { + c.hub.unregister <- c + c.conn.Close() + }() + for { + _, _, err := c.conn.ReadMessage() + if err != nil { + if websocket.IsUnexpectedCloseError(err, websocket.CloseGoingAway) { + log.Printf("An error happened when reading from the Websocket client: %v", err) + } + break + } + } +} + +func (c *Client) write(mt int, payload []byte) error { + c.conn.SetWriteDeadline(time.Now().Add(writeWait)) + return c.conn.WriteMessage(mt, payload) +} + +func (c *Client) writePump() { + ticker := time.NewTicker(pingPeriod) + defer func() { + ticker.Stop() + c.conn.Close() + }() + for { + select { + case message, ok := <-c.send: + if !ok { + c.write(websocket.CloseMessage, []byte{}) + return + } + + c.conn.SetWriteDeadline(time.Now().Add(writeWait)) + w, err := c.conn.NextWriter(websocket.TextMessage) + if err != nil { + return + } + w.Write(message) + + n := len(c.send) + for i := 0; i < n; i++ { + w.Write([]byte{'\n'}) + w.Write(<-c.send) + } + + if err := w.Close(); err != nil { + return + } + case <-ticker.C: + if err := c.write(websocket.PingMessage, []byte{}); err != nil { + return + } + } + } +} diff --git a/internal/ws/hub.go b/internal/ws/hub.go new file mode 100644 index 0000000..5b5cf7f --- /dev/null +++ b/internal/ws/hub.go @@ -0,0 +1,56 @@ +package ws + +import "bytes" + +type Hub struct { + clients map[*Client]bool + Broadcast chan []byte + register chan *Client + unregister chan *Client + reload []byte +} + +func NewHub() *Hub { + return &Hub{ + Broadcast: make(chan []byte), + register: make(chan *Client), + unregister: make(chan *Client), + clients: make(map[*Client]bool), + reload: []byte("reload"), + } +} + +func (h *Hub) Run() { + for { + select { + case client := <-h.register: + h.clients[client] = true + case client := <-h.unregister: + if _, ok := h.clients[client]; ok { + delete(h.clients, client) + close(client.send) + } + case message := <-h.Broadcast: + for client := range h.clients { + select { + case client.send <- message: + default: + close(client.send) + delete(h.clients, client) + } + } + } + } +} + +func (h *Hub) SendError(mes string) { + h.Broadcast <- bytes.TrimSpace([]byte(mes)) +} + +func (h *Hub) SendErrorBytes(mes []byte) { + h.Broadcast <- bytes.TrimSpace(mes) +} + +func (h *Hub) SendReload() { + h.Broadcast <- bytes.TrimSpace(h.reload) +} diff --git a/internal/ws/script.go b/internal/ws/script.go new file mode 100644 index 0000000..b2c3f2d --- /dev/null +++ b/internal/ws/script.go @@ -0,0 +1,101 @@ +package ws + +import ( + "html/template" + "os" + "strings" +) + +const HotReloadScript = ` + +` + +const DefaultHtmlFile = ` + + + + + + + Document + + + +

Hot reload script

+

+ Insert this script into your index .php or .html file and it will reload every time rebuild your project,
+ or in the plugin options specify the path to your .html file, then the script will be added there automatically. +

+
+		
+<script type="text/javascript">
+	function tryConnectToReload(address) {
+		const conn = new WebSocket(address);
+		conn.onclose = () => setTimeout(() => tryConnectToReload(address), 2000);
+		conn.onmessage = evt => evt.data === "reload" ? location.reload() : console.error(evt.data);
+	}
+	try {
+		window["WebSocket"] ? tryConnectToReload("ws://localhost{port}/connect") : console.log("Your browser does not support WebSockets, cannot connect to the Reload service.");
+	} catch (ex) {
+		console.error('Exception during connecting to Reload:', ex);
+	}
+</script>
+		
+	
+

Plugin:

+

esbuild-dev-server

+ + +` + +func GetDefaultHtmlFile(port string) (*template.Template, error) { + tmpl := template.New("index") + tmpl, err := tmpl.Parse(strings.Replace(DefaultHtmlFile, "{port}", port, -1)) + if err != nil { + return nil, err + } + return tmpl, nil +} + +func AddHotReloadScript(path string, port string) (*template.Template, error) { + f, err := os.ReadFile(path) + if err != nil { + return nil, err + } + html := strings.Replace(string(f), "", strings.Replace(HotReloadScript, "{port}", port, -1)+"", -1) + tmpl := template.New("index") + tmpl, err = tmpl.Parse(html) + if err != nil { + return nil, err + } + return tmpl, nil +} diff --git a/lib/.eslintignore b/lib/.eslintignore new file mode 100644 index 0000000..59d2499 --- /dev/null +++ b/lib/.eslintignore @@ -0,0 +1,2 @@ +.eslintrc.js + diff --git a/lib/.eslintrc.js b/lib/.eslintrc.js new file mode 100644 index 0000000..21de4c9 --- /dev/null +++ b/lib/.eslintrc.js @@ -0,0 +1,13 @@ +module.exports = { + "root": true, + "parser": "@typescript-eslint/parser", + "extends": [ + "plugin:@typescript-eslint/eslint-recommended", + "plugin:@typescript-eslint/recommended" + ], + "plugins": ["@typescript-eslint"], + "parserOptions": { + "ecmaVersion": 12, + "sourceType": "module" + }, +}; diff --git a/lib/package.json b/lib/package.json new file mode 100644 index 0000000..e0d624e --- /dev/null +++ b/lib/package.json @@ -0,0 +1,45 @@ +{ + "name": "esbuild-dev-server", + "version": "0.3.0", + "description": "An fast JavaScript hot dev local server.", + "main": "src/esbuild-dev-server.js", + "scripts": { + "build": "tsc --declaration --emitDeclarationOnly --outfile ../npm/esbuild-dev-server/lib/esbuild-dev-server.d.ts", + "lint": "eslint src" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT", + "devDependencies": { + "@types/node": "^16.10.2", + "@typescript-eslint/eslint-plugin": "^4.32.0", + "@typescript-eslint/parser": "^4.32.0", + "eslint": "^7.32.0", + "eslint-plugin-import": "^2.24.2", + "ts-loader": "^9.2.6", + "typescript": "^4.4.3" + } +} diff --git a/lib/src/esbuild-dev-server.ts b/lib/src/esbuild-dev-server.ts new file mode 100644 index 0000000..d069240 --- /dev/null +++ b/lib/src/esbuild-dev-server.ts @@ -0,0 +1,106 @@ +// Copyright (c) 2021 Falldot +// License: MIT License +// MIT License web page: https://opensource.org/licenses/MIT +import { request } from "http"; +import { spawn } from "child_process"; +import os = require('os'); + +/** +* Dev server options. +* @type {string} port start local server +* @type {string} Root html file +* @type {string} Stacic files +* @type {string} Working directory +* @type {() => void} Event before rebuild +* @type {() => void} Event after rebuild +*/ +export interface DevServerOptions { + port: string, + index: string, + staticDir: string, + watchDir: string, + onBeforeRebuild: () => void + onAfterRebuild: () => void +} + +let Options: DevServerOptions; + +/** +* Start dev server. +* @param {BuildIncremental} result esbuild context. +* @return {Promise} +*/ +const startServer = (result: any): Promise => new Promise((resolve, reject) => { + const platform = `esbuild-dev-server-${process.platform}-${os.arch()}`; + const ls = spawn(__dirname + `/../../${platform}/devserver`, ['-p', Options.port, '-i', Options.index, '-s', Options.staticDir, '-w', Options.watchDir]); + ls.stdout.on("data", data => { + if (`${data}` === "Reload") { + result.rebuild().then(() => { + sendReload(); + }).catch((err: any) => { + sendError(err.message); + }) + } else { + console.log(`${data}`); + } + }); + ls.stderr.on("data", data => { + console.log(`${data}`); + }); + ls.on('error', error => { + reject(error); + }); + ls.on("close", code => { + resolve(code); + }); +}); + +/** +* Send error dev server. +* @param {string} message Message to dev server. +* @return {Promise} +*/ +export const sendError = (message: string): Promise => new Promise((resolve, reject) => { + const req = request({ + host: 'localhost', + port: Options.port, + path: '/error', + method: 'POST', + headers: { + 'Content-Type': 'text/plain' + } + }).on("error", err => reject(err)); + const b = Buffer.alloc(message.length); + b.write(message); + req.write(b); + req.end(); + resolve(null); +}); + +/** +* Send reload dev server. +* @return {Promise} +*/ +export const sendReload = (): Promise => new Promise((resolve, reject) => { + request({ + host: 'localhost', + port: Options.port, + path: '/reload', + method: 'GET' + }).on("error", err => reject(err)).end(); + resolve(null); +}); + +/** +* Set dev server options for esbuild. +* @param {Promise} build esbuild options. +* @param {Promise} options dev-server options. +*/ +export const start = (build: Promise, options: DevServerOptions) => { + build.then((result: any) => { + Options = options; + startServer(result) + }).catch((err: any) => { + console.log(err) + }) +} \ No newline at end of file diff --git a/lib/tsconfig.json b/lib/tsconfig.json new file mode 100644 index 0000000..545ddc5 --- /dev/null +++ b/lib/tsconfig.json @@ -0,0 +1,14 @@ +{ + "compilerOptions": { + "target": "ESNext", + "module": "CommonJS", + "lib": ["ESNext", "dom"], + "declaration": true, + "sourceMap": true, + "noImplicitAny": true, + "strict": true, + }, + "exclude": [ + "node_modules", + ] + } \ No newline at end of file diff --git a/lib/yarn.lock b/lib/yarn.lock new file mode 100644 index 0000000..d478a6f --- /dev/null +++ b/lib/yarn.lock @@ -0,0 +1,1689 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@babel/code-frame@7.12.11": + version "7.12.11" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.11.tgz#f4ad435aa263db935b8f10f2c552d23fb716a63f" + integrity sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH1RcIw== + dependencies: + "@babel/highlight" "^7.10.4" + +"@babel/helper-validator-identifier@^7.14.5": + version "7.15.7" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz#220df993bfe904a4a6b02ab4f3385a5ebf6e2389" + integrity sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w== + +"@babel/highlight@^7.10.4": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.14.5.tgz#6861a52f03966405001f6aa534a01a24d99e8cd9" + integrity sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg== + dependencies: + "@babel/helper-validator-identifier" "^7.14.5" + chalk "^2.0.0" + js-tokens "^4.0.0" + +"@eslint/eslintrc@^0.4.3": + version "0.4.3" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-0.4.3.tgz#9e42981ef035beb3dd49add17acb96e8ff6f394c" + integrity sha512-J6KFFz5QCYUJq3pf0mjEcCJVERbzv71PUIDczuh9JkwGEzced6CO5ADLHB1rbf/+oPBtoPfMYNOpGDzCANlbXw== + dependencies: + ajv "^6.12.4" + debug "^4.1.1" + espree "^7.3.0" + globals "^13.9.0" + ignore "^4.0.6" + import-fresh "^3.2.1" + js-yaml "^3.13.1" + minimatch "^3.0.4" + strip-json-comments "^3.1.1" + +"@humanwhocodes/config-array@^0.5.0": + version "0.5.0" + resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.5.0.tgz#1407967d4c6eecd7388f83acf1eaf4d0c6e58ef9" + integrity sha512-FagtKFz74XrTl7y6HCzQpwDfXP0yhxe9lHLD1UZxjvZIcbyRz8zTFF/yYNfSfzU414eDwZ1SrO0Qvtyf+wFMQg== + dependencies: + "@humanwhocodes/object-schema" "^1.2.0" + debug "^4.1.1" + minimatch "^3.0.4" + +"@humanwhocodes/object-schema@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.0.tgz#87de7af9c231826fdd68ac7258f77c429e0e5fcf" + integrity sha512-wdppn25U8z/2yiaT6YGquE6X8sSv7hNMWSXYSSU1jGv/yd6XqjXgTDJ8KP4NgjTXfJ3GbRjeeb8RTV7a/VpM+w== + +"@nodelib/fs.scandir@2.1.5": + version "2.1.5" + resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" + integrity sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g== + dependencies: + "@nodelib/fs.stat" "2.0.5" + run-parallel "^1.1.9" + +"@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz#5bd262af94e9d25bd1e71b05deed44876a222e8b" + integrity sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A== + +"@nodelib/fs.walk@^1.2.3": + version "1.2.8" + resolved "https://registry.yarnpkg.com/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a" + integrity sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg== + dependencies: + "@nodelib/fs.scandir" "2.1.5" + fastq "^1.6.0" + +"@types/json-schema@^7.0.7": + version "7.0.9" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.9.tgz#97edc9037ea0c38585320b28964dde3b39e4660d" + integrity sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ== + +"@types/json5@^0.0.29": + version "0.0.29" + resolved "https://registry.yarnpkg.com/@types/json5/-/json5-0.0.29.tgz#ee28707ae94e11d2b827bcbe5270bcea7f3e71ee" + integrity sha1-7ihweulOEdK4J7y+UnC86n8+ce4= + +"@types/node@^16.10.2": + version "16.10.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-16.10.2.tgz#5764ca9aa94470adb4e1185fe2e9f19458992b2e" + integrity sha512-zCclL4/rx+W5SQTzFs9wyvvyCwoK9QtBpratqz2IYJ3O8Umrn0m3nsTv0wQBk9sRGpvUe9CwPDrQFB10f1FIjQ== + +"@typescript-eslint/eslint-plugin@^4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.32.0.tgz#46d2370ae9311092f2a6f7246d28357daf2d4e89" + integrity sha512-+OWTuWRSbWI1KDK8iEyG/6uK2rTm3kpS38wuVifGUTDB6kjEuNrzBI1MUtxnkneuWG/23QehABe2zHHrj+4yuA== + dependencies: + "@typescript-eslint/experimental-utils" "4.32.0" + "@typescript-eslint/scope-manager" "4.32.0" + debug "^4.3.1" + functional-red-black-tree "^1.0.1" + ignore "^5.1.8" + regexpp "^3.1.0" + semver "^7.3.5" + tsutils "^3.21.0" + +"@typescript-eslint/experimental-utils@4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-4.32.0.tgz#53a8267d16ca5a79134739129871966c56a59dc4" + integrity sha512-WLoXcc+cQufxRYjTWr4kFt0DyEv6hDgSaFqYhIzQZ05cF+kXfqXdUh+//kgquPJVUBbL3oQGKQxwPbLxHRqm6A== + dependencies: + "@types/json-schema" "^7.0.7" + "@typescript-eslint/scope-manager" "4.32.0" + "@typescript-eslint/types" "4.32.0" + "@typescript-eslint/typescript-estree" "4.32.0" + eslint-scope "^5.1.1" + eslint-utils "^3.0.0" + +"@typescript-eslint/parser@^4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-4.32.0.tgz#751ecca0e2fecd3d44484a9b3049ffc1871616e5" + integrity sha512-lhtYqQ2iEPV5JqV7K+uOVlPePjClj4dOw7K4/Z1F2yvjIUvyr13yJnDzkK6uon4BjHYuHy3EG0c2Z9jEhFk56w== + dependencies: + "@typescript-eslint/scope-manager" "4.32.0" + "@typescript-eslint/types" "4.32.0" + "@typescript-eslint/typescript-estree" "4.32.0" + debug "^4.3.1" + +"@typescript-eslint/scope-manager@4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-4.32.0.tgz#e03c8668f8b954072b3f944d5b799c0c9225a7d5" + integrity sha512-DK+fMSHdM216C0OM/KR1lHXjP1CNtVIhJ54kQxfOE6x8UGFAjha8cXgDMBEIYS2XCYjjCtvTkjQYwL3uvGOo0w== + dependencies: + "@typescript-eslint/types" "4.32.0" + "@typescript-eslint/visitor-keys" "4.32.0" + +"@typescript-eslint/types@4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-4.32.0.tgz#52c633c18da47aee09449144bf59565ab36df00d" + integrity sha512-LE7Z7BAv0E2UvqzogssGf1x7GPpUalgG07nGCBYb1oK4mFsOiFC/VrSMKbZQzFJdN2JL5XYmsx7C7FX9p9ns0w== + +"@typescript-eslint/typescript-estree@4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-4.32.0.tgz#db00ccc41ccedc8d7367ea3f50c6994b8efa9f3b" + integrity sha512-tRYCgJ3g1UjMw1cGG8Yn1KzOzNlQ6u1h9AmEtPhb5V5a1TmiHWcRyF/Ic+91M4f43QeChyYlVTcf3DvDTZR9vw== + dependencies: + "@typescript-eslint/types" "4.32.0" + "@typescript-eslint/visitor-keys" "4.32.0" + debug "^4.3.1" + globby "^11.0.3" + is-glob "^4.0.1" + semver "^7.3.5" + tsutils "^3.21.0" + +"@typescript-eslint/visitor-keys@4.32.0": + version "4.32.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-4.32.0.tgz#455ba8b51242f2722a497ffae29313f33b14cb7f" + integrity sha512-e7NE0qz8W+atzv3Cy9qaQ7BTLwWsm084Z0c4nIO2l3Bp6u9WIgdqCgyPyV5oSPDMIW3b20H59OOCmVk3jw3Ptw== + dependencies: + "@typescript-eslint/types" "4.32.0" + eslint-visitor-keys "^2.0.0" + +acorn-jsx@^5.3.1: + version "5.3.2" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" + integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== + +acorn@^7.4.0: + version "7.4.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" + integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== + +ajv@^6.10.0, ajv@^6.12.4: + version "6.12.6" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== + dependencies: + fast-deep-equal "^3.1.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + +ajv@^8.0.1: + version "8.6.3" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.6.3.tgz#11a66527761dc3e9a3845ea775d2d3c0414e8764" + integrity sha512-SMJOdDP6LqTkD0Uq8qLi+gMwSt0imXLSV080qFVwJCpH9U6Mb+SUGHAXM0KNbcBPguytWyvFxcHgMLe2D2XSpw== + dependencies: + fast-deep-equal "^3.1.1" + json-schema-traverse "^1.0.0" + require-from-string "^2.0.2" + uri-js "^4.2.2" + +ansi-colors@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-4.1.1.tgz#cbb9ae256bf750af1eab344f229aa27fe94ba348" + integrity sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA== + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== + +ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== + dependencies: + color-convert "^1.9.0" + +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== + dependencies: + sprintf-js "~1.0.2" + +array-includes@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/array-includes/-/array-includes-3.1.3.tgz#c7f619b382ad2afaf5326cddfdc0afc61af7690a" + integrity sha512-gcem1KlBU7c9rB+Rq8/3PPKsK2kjqeEBa3bD5kkQo4nYlOHQCJqIJFqBXDEfwaRuYTT4E+FxA9xez7Gf/e3Q7A== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.18.0-next.2" + get-intrinsic "^1.1.1" + is-string "^1.0.5" + +array-union@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/array-union/-/array-union-2.1.0.tgz#b798420adbeb1de828d84acd8a2e23d3efe85e8d" + integrity sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw== + +array.prototype.flat@^1.2.4: + version "1.2.4" + resolved "https://registry.yarnpkg.com/array.prototype.flat/-/array.prototype.flat-1.2.4.tgz#6ef638b43312bd401b4c6199fdec7e2dc9e9a123" + integrity sha512-4470Xi3GAPAjZqFcljX2xzckv1qeKPizoNkiS0+O4IoPR2ZNpcjE0pkhdihlDouK+x6QOast26B4Q/O9DJnwSg== + dependencies: + call-bind "^1.0.0" + define-properties "^1.1.3" + es-abstract "^1.18.0-next.1" + +astral-regex@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-2.0.0.tgz#483143c567aeed4785759c0865786dc77d7d2e31" + integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== + +balanced-match@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== + +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + +braces@^3.0.1: + version "3.0.2" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== + dependencies: + fill-range "^7.0.1" + +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + +callsites@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== + +chalk@^2.0.0: + version "2.4.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chalk@^4.0.0, chalk@^4.1.0: + version "4.1.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= + +cross-spawn@^7.0.2: + version "7.0.3" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" + integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w== + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" + +debug@^2.6.9: + version "2.6.9" + resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" + integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== + dependencies: + ms "2.0.0" + +debug@^3.2.7: + version "3.2.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" + integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== + dependencies: + ms "^2.1.1" + +debug@^4.0.1, debug@^4.1.1, debug@^4.3.1: + version "4.3.2" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.2.tgz#f0a49c18ac8779e31d4a0c6029dfb76873c7428b" + integrity sha512-mOp8wKcvj7XxC78zLgw/ZA+6TSgkoE2C/ienthhRD298T7UNwAg9diBpLRxC0mOezLl4B0xV7M0cCO6P/O0Xhw== + dependencies: + ms "2.1.2" + +deep-is@^0.1.3: + version "0.1.4" + resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.4.tgz#a6f2dce612fadd2ef1f519b73551f17e85199831" + integrity sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ== + +define-properties@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" + integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== + dependencies: + object-keys "^1.0.12" + +dir-glob@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-3.0.1.tgz#56dbf73d992a4a93ba1584f4534063fd2e41717f" + integrity sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA== + dependencies: + path-type "^4.0.0" + +doctrine@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== + dependencies: + esutils "^2.0.2" + +doctrine@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" + integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w== + dependencies: + esutils "^2.0.2" + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +enhanced-resolve@^5.0.0: + version "5.8.3" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.8.3.tgz#6d552d465cce0423f5b3d718511ea53826a7b2f0" + integrity sha512-EGAbGvH7j7Xt2nc0E7D99La1OiEs8LnyimkRgwExpUMScN6O+3x9tIWs7PLQZVNx4YD+00skHXPXi1yQHpAmZA== + dependencies: + graceful-fs "^4.2.4" + tapable "^2.2.0" + +enquirer@^2.3.5: + version "2.3.6" + resolved "https://registry.yarnpkg.com/enquirer/-/enquirer-2.3.6.tgz#2a7fe5dd634a1e4125a975ec994ff5456dc3734d" + integrity sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg== + dependencies: + ansi-colors "^4.1.1" + +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== + dependencies: + is-arrayish "^0.2.1" + +es-abstract@^1.18.0-next.1, es-abstract@^1.18.0-next.2, es-abstract@^1.18.2: + version "1.18.7" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.18.7.tgz#122daaa523d0a10b0f1be8ed4ce1ee68330c5bb2" + integrity sha512-uFG1gyVX91tZIiDWNmPsL8XNpiCk/6tkB7MZphoSJflS4w+KgWyQ2gjCVDnsPxFAo9WjRXG3eqONNYdfbJjAtw== + dependencies: + call-bind "^1.0.2" + es-to-primitive "^1.2.1" + function-bind "^1.1.1" + get-intrinsic "^1.1.1" + get-symbol-description "^1.0.0" + has "^1.0.3" + has-symbols "^1.0.2" + internal-slot "^1.0.3" + is-callable "^1.2.4" + is-negative-zero "^2.0.1" + is-regex "^1.1.4" + is-string "^1.0.7" + object-inspect "^1.11.0" + object-keys "^1.1.1" + object.assign "^4.1.2" + string.prototype.trimend "^1.0.4" + string.prototype.trimstart "^1.0.4" + unbox-primitive "^1.0.1" + +es-to-primitive@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.1.tgz#e55cd4c9cdc188bcefb03b366c736323fc5c898a" + integrity sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA== + dependencies: + is-callable "^1.1.4" + is-date-object "^1.0.1" + is-symbol "^1.0.2" + +esbuild-android-arm64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.13.13.tgz#da07b5fb2daf7d83dcd725f7cf58a6758e6e702a" + integrity sha512-T02aneWWguJrF082jZworjU6vm8f4UQ+IH2K3HREtlqoY9voiJUwHLRL6khRlsNLzVglqgqb7a3HfGx7hAADCQ== + +esbuild-darwin-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.13.13.tgz#e94e9fd3b4b5455a2e675cd084a19a71b6904bbf" + integrity sha512-wkaiGAsN/09X9kDlkxFfbbIgR78SNjMOfUhoel3CqKBDsi9uZhw7HBNHNxTzYUK8X8LAKFpbODgcRB3b/I8gHA== + +esbuild-darwin-arm64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.13.13.tgz#8c320eafbb3ba2c70d8062128c5b71503e342471" + integrity sha512-b02/nNKGSV85Gw9pUCI5B48AYjk0vFggDeom0S6QMP/cEDtjSh1WVfoIFNAaLA0MHWfue8KBwoGVsN7rBshs4g== + +esbuild-freebsd-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.13.13.tgz#ce0ca5b8c4c274cfebc9326f9b316834bd9dd151" + integrity sha512-ALgXYNYDzk9YPVk80A+G4vz2D22Gv4j4y25exDBGgqTcwrVQP8rf/rjwUjHoh9apP76oLbUZTmUmvCMuTI1V9A== + +esbuild-freebsd-arm64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.13.13.tgz#463da17562fdcfdf03b3b94b28497d8d8dcc8f62" + integrity sha512-uFvkCpsZ1yqWQuonw5T1WZ4j59xP/PCvtu6I4pbLejhNo4nwjW6YalqnBvBSORq5/Ifo9S/wsIlVHzkzEwdtlw== + +esbuild-linux-32@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.13.13.tgz#2035793160da2c4be48a929e5bafb14a31789acc" + integrity sha512-yxR9BBwEPs9acVEwTrEE2JJNHYVuPQC9YGjRfbNqtyfK/vVBQYuw8JaeRFAvFs3pVJdQD0C2BNP4q9d62SCP4w== + +esbuild-linux-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.13.13.tgz#fbe4802a8168c6d339d0749f977b099449b56f22" + integrity sha512-kzhjlrlJ+6ESRB/n12WTGll94+y+HFeyoWsOrLo/Si0s0f+Vip4b8vlnG0GSiS6JTsWYAtGHReGczFOaETlKIw== + +esbuild-linux-arm64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.13.13.tgz#f08d98df28d436ed4aad1529615822bb74d4d978" + integrity sha512-KMrEfnVbmmJxT3vfTnPv/AiXpBFbbyExH13BsUGy1HZRPFMi5Gev5gk8kJIZCQSRfNR17aqq8sO5Crm2KpZkng== + +esbuild-linux-arm@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.13.13.tgz#6f968c3a98b64e30c80b212384192d0cfcb32e7f" + integrity sha512-hXub4pcEds+U1TfvLp1maJ+GHRw7oizvzbGRdUvVDwtITtjq8qpHV5Q5hWNNn6Q+b3b2UxF03JcgnpzCw96nUQ== + +esbuild-linux-mips64le@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.13.13.tgz#690c78dc4725efe7d06a1431287966fbf7774c7f" + integrity sha512-cJT9O1LYljqnnqlHaS0hdG73t7hHzF3zcN0BPsjvBq+5Ad47VJun+/IG4inPhk8ta0aEDK6LdP+F9299xa483w== + +esbuild-linux-ppc64le@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.13.13.tgz#7ec9048502de46754567e734aae7aebd2df6df02" + integrity sha512-+rghW8st6/7O6QJqAjVK3eXzKkZqYAw6LgHv7yTMiJ6ASnNvghSeOcIvXFep3W2oaJc35SgSPf21Ugh0o777qQ== + +esbuild-netbsd-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.13.13.tgz#439bdaefffa03a8fa84324f5d83d636f548a2de3" + integrity sha512-A/B7rwmzPdzF8c3mht5TukbnNwY5qMJqes09ou0RSzA5/jm7Jwl/8z853ofujTFOLhkNHUf002EAgokzSgEMpQ== + +esbuild-openbsd-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.13.13.tgz#c9958e5291a00a3090c1ec482d6bcdf2d5b5d107" + integrity sha512-szwtuRA4rXKT3BbwoGpsff6G7nGxdKgUbW9LQo6nm0TVCCjDNDC/LXxT994duIW8Tyq04xZzzZSW7x7ttDiw1w== + +esbuild-sunos-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.13.13.tgz#ac9ead8287379cd2f6d00bd38c5997fda9c1179e" + integrity sha512-ihyds9O48tVOYF48iaHYUK/boU5zRaLOXFS+OOL3ceD39AyHo46HVmsJLc7A2ez0AxNZCxuhu+P9OxfPfycTYQ== + +esbuild-windows-32@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.13.13.tgz#a3820fc86631ca594cb7b348514b5cc3f058cfd6" + integrity sha512-h2RTYwpG4ldGVJlbmORObmilzL8EECy8BFiF8trWE1ZPHLpECE9//J3Bi+W3eDUuv/TqUbiNpGrq4t/odbayUw== + +esbuild-windows-64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.13.13.tgz#1da748441f228d75dff474ddb7d584b81887323c" + integrity sha512-oMrgjP4CjONvDHe7IZXHrMk3wX5Lof/IwFEIbwbhgbXGBaN2dke9PkViTiXC3zGJSGpMvATXVplEhlInJ0drHA== + +esbuild-windows-arm64@0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.13.13.tgz#06dfa52a6b178a5932a9a6e2fdb240c09e6da30c" + integrity sha512-6fsDfTuTvltYB5k+QPah/x7LrI2+OLAJLE3bWLDiZI6E8wXMQU+wLqtEO/U/RvJgVY1loPs5eMpUBpVajczh1A== + +esbuild@^0.13.13: + version "0.13.13" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.13.13.tgz#0b5399c20f219f663c8c1048436fb0f59ab17a41" + integrity sha512-Z17A/R6D0b4s3MousytQ/5i7mTCbaF+Ua/yPfoe71vdTv4KBvVAvQ/6ytMngM2DwGJosl8WxaD75NOQl2QF26Q== + optionalDependencies: + esbuild-android-arm64 "0.13.13" + esbuild-darwin-64 "0.13.13" + esbuild-darwin-arm64 "0.13.13" + esbuild-freebsd-64 "0.13.13" + esbuild-freebsd-arm64 "0.13.13" + esbuild-linux-32 "0.13.13" + esbuild-linux-64 "0.13.13" + esbuild-linux-arm "0.13.13" + esbuild-linux-arm64 "0.13.13" + esbuild-linux-mips64le "0.13.13" + esbuild-linux-ppc64le "0.13.13" + esbuild-netbsd-64 "0.13.13" + esbuild-openbsd-64 "0.13.13" + esbuild-sunos-64 "0.13.13" + esbuild-windows-32 "0.13.13" + esbuild-windows-64 "0.13.13" + esbuild-windows-arm64 "0.13.13" + +escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" + integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= + +escape-string-regexp@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" + integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== + +eslint-import-resolver-node@^0.3.6: + version "0.3.6" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.6.tgz#4048b958395da89668252001dbd9eca6b83bacbd" + integrity sha512-0En0w03NRVMn9Uiyn8YRPDKvWjxCWkslUEhGNTdGx15RvPJYQ+lbOlqrlNI2vEAs4pDYK4f/HN2TbDmk5TP0iw== + dependencies: + debug "^3.2.7" + resolve "^1.20.0" + +eslint-module-utils@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.6.2.tgz#94e5540dd15fe1522e8ffa3ec8db3b7fa7e7a534" + integrity sha512-QG8pcgThYOuqxupd06oYTZoNOGaUdTY1PqK+oS6ElF6vs4pBdk/aYxFVQQXzcrAqp9m7cl7lb2ubazX+g16k2Q== + dependencies: + debug "^3.2.7" + pkg-dir "^2.0.0" + +eslint-plugin-import@^2.24.2: + version "2.24.2" + resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.24.2.tgz#2c8cd2e341f3885918ee27d18479910ade7bb4da" + integrity sha512-hNVtyhiEtZmpsabL4neEj+6M5DCLgpYyG9nzJY8lZQeQXEn5UPW1DpUdsMHMXsq98dbNm7nt1w9ZMSVpfJdi8Q== + dependencies: + array-includes "^3.1.3" + array.prototype.flat "^1.2.4" + debug "^2.6.9" + doctrine "^2.1.0" + eslint-import-resolver-node "^0.3.6" + eslint-module-utils "^2.6.2" + find-up "^2.0.0" + has "^1.0.3" + is-core-module "^2.6.0" + minimatch "^3.0.4" + object.values "^1.1.4" + pkg-up "^2.0.0" + read-pkg-up "^3.0.0" + resolve "^1.20.0" + tsconfig-paths "^3.11.0" + +eslint-scope@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" + integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== + dependencies: + esrecurse "^4.3.0" + estraverse "^4.1.1" + +eslint-utils@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-2.1.0.tgz#d2de5e03424e707dc10c74068ddedae708741b27" + integrity sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg== + dependencies: + eslint-visitor-keys "^1.1.0" + +eslint-utils@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-3.0.0.tgz#8aebaface7345bb33559db0a1f13a1d2d48c3672" + integrity sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA== + dependencies: + eslint-visitor-keys "^2.0.0" + +eslint-visitor-keys@^1.1.0, eslint-visitor-keys@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e" + integrity sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ== + +eslint-visitor-keys@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz#f65328259305927392c938ed44eb0a5c9b2bd303" + integrity sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw== + +eslint@^7.32.0: + version "7.32.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.32.0.tgz#c6d328a14be3fb08c8d1d21e12c02fdb7a2a812d" + integrity sha512-VHZ8gX+EDfz+97jGcgyGCyRia/dPOd6Xh9yPv8Bl1+SoaIwD+a/vlrOmGRUyOYu7MwUhc7CxqeaDZU13S4+EpA== + dependencies: + "@babel/code-frame" "7.12.11" + "@eslint/eslintrc" "^0.4.3" + "@humanwhocodes/config-array" "^0.5.0" + ajv "^6.10.0" + chalk "^4.0.0" + cross-spawn "^7.0.2" + debug "^4.0.1" + doctrine "^3.0.0" + enquirer "^2.3.5" + escape-string-regexp "^4.0.0" + eslint-scope "^5.1.1" + eslint-utils "^2.1.0" + eslint-visitor-keys "^2.0.0" + espree "^7.3.1" + esquery "^1.4.0" + esutils "^2.0.2" + fast-deep-equal "^3.1.3" + file-entry-cache "^6.0.1" + functional-red-black-tree "^1.0.1" + glob-parent "^5.1.2" + globals "^13.6.0" + ignore "^4.0.6" + import-fresh "^3.0.0" + imurmurhash "^0.1.4" + is-glob "^4.0.0" + js-yaml "^3.13.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.4.1" + lodash.merge "^4.6.2" + minimatch "^3.0.4" + natural-compare "^1.4.0" + optionator "^0.9.1" + progress "^2.0.0" + regexpp "^3.1.0" + semver "^7.2.1" + strip-ansi "^6.0.0" + strip-json-comments "^3.1.0" + table "^6.0.9" + text-table "^0.2.0" + v8-compile-cache "^2.0.3" + +espree@^7.3.0, espree@^7.3.1: + version "7.3.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-7.3.1.tgz#f2df330b752c6f55019f8bd89b7660039c1bbbb6" + integrity sha512-v3JCNCE64umkFpmkFGqzVKsOT0tN1Zr+ueqLZfpV1Ob8e+CEgPWa+OxCoGH3tnhimMKIaBm4m/vaRpJ/krRz2g== + dependencies: + acorn "^7.4.0" + acorn-jsx "^5.3.1" + eslint-visitor-keys "^1.3.0" + +esprima@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== + +esquery@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" + integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== + dependencies: + estraverse "^5.1.0" + +esrecurse@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" + integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== + dependencies: + estraverse "^5.2.0" + +estraverse@^4.1.1: + version "4.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== + +estraverse@^5.1.0, estraverse@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.2.0.tgz#307df42547e6cc7324d3cf03c155d5cdb8c53880" + integrity sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ== + +esutils@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== + +fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" + integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== + +fast-glob@^3.1.1: + version "3.2.7" + resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.7.tgz#fd6cb7a2d7e9aa7a7846111e85a196d6b2f766a1" + integrity sha512-rYGMRwip6lUMvYD3BTScMwT1HtAs2d71SMv66Vrxs0IekGZEjhM0pcMfjQPnknBt2zeCwQMEupiN02ZP4DiT1Q== + dependencies: + "@nodelib/fs.stat" "^2.0.2" + "@nodelib/fs.walk" "^1.2.3" + glob-parent "^5.1.2" + merge2 "^1.3.0" + micromatch "^4.0.4" + +fast-json-stable-stringify@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== + +fast-levenshtein@^2.0.6: + version "2.0.6" + resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" + integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= + +fastq@^1.6.0: + version "1.13.0" + resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.13.0.tgz#616760f88a7526bdfc596b7cab8c18938c36b98c" + integrity sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw== + dependencies: + reusify "^1.0.4" + +file-entry-cache@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-6.0.1.tgz#211b2dd9659cb0394b073e7323ac3c933d522027" + integrity sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg== + dependencies: + flat-cache "^3.0.4" + +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== + dependencies: + to-regex-range "^5.0.1" + +find-up@^2.0.0, find-up@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" + integrity sha1-RdG35QbHF93UgndaK3eSCjwMV6c= + dependencies: + locate-path "^2.0.0" + +flat-cache@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-3.0.4.tgz#61b0338302b2fe9f957dcc32fc2a87f1c3048b11" + integrity sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg== + dependencies: + flatted "^3.1.0" + rimraf "^3.0.2" + +flatted@^3.1.0: + version "3.2.2" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.2.tgz#64bfed5cb68fe3ca78b3eb214ad97b63bedce561" + integrity sha512-JaTY/wtrcSyvXJl4IMFHPKyFur1sE9AUqc0QnhOaJ0CxHtAoIV8pYDzeEfAaNEtGkOfq4gr3LBFmdXW5mOQFnA== + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= + +get-intrinsic@^1.0.2, get-intrinsic@^1.1.0, get-intrinsic@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.1.tgz#15f59f376f855c446963948f0d24cd3637b4abc6" + integrity sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-symbols "^1.0.1" + +get-symbol-description@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" + integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + +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== + dependencies: + is-glob "^4.0.1" + +glob@^7.1.3: + version "7.2.0" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.0.tgz#d15535af7732e02e948f4c41628bd910293f6023" + integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +globals@^13.6.0, globals@^13.9.0: + version "13.11.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.11.0.tgz#40ef678da117fe7bd2e28f1fab24951bd0255be7" + integrity sha512-08/xrJ7wQjK9kkkRoI3OFUBbLx4f+6x3SGwcPvQ0QH6goFDrOU2oyAWrmh3dJezu65buo+HBMzAMQy6rovVC3g== + dependencies: + type-fest "^0.20.2" + +globby@^11.0.3: + version "11.0.4" + resolved "https://registry.yarnpkg.com/globby/-/globby-11.0.4.tgz#2cbaff77c2f2a62e71e9b2813a67b97a3a3001a5" + integrity sha512-9O4MVG9ioZJ08ffbcyVYyLOJLk5JQ688pJ4eMGLpdWLHq/Wr1D9BlriLQyL0E+jbkuePVZXYFj47QM/v093wHg== + dependencies: + array-union "^2.1.0" + dir-glob "^3.0.1" + fast-glob "^3.1.1" + ignore "^5.1.4" + merge2 "^1.3.0" + slash "^3.0.0" + +graceful-fs@^4.1.2, graceful-fs@^4.2.4: + version "4.2.8" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.8.tgz#e412b8d33f5e006593cbd3cee6df9f2cebbe802a" + integrity sha512-qkIilPUYcNhJpd33n0GBXTB1MMPp14TxEsEs0pTrsSVucApsYzW5V+Q8Qxhik6KU3evy+qkAAowTByymK0avdg== + +has-bigints@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.1.tgz#64fe6acb020673e3b78db035a5af69aa9d07b113" + integrity sha512-LSBS2LjbNBTf6287JEbEzvJgftkF5qFkmCo9hDRpAzKhUOlJ+hx8dd4USs00SgsUNwc4617J9ki5YtEClM2ffA== + +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" + integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= + +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +has-symbols@^1.0.1, has-symbols@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.2.tgz#165d3070c00309752a1236a479331e3ac56f1423" + integrity sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw== + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== + dependencies: + has-symbols "^1.0.2" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +hosted-git-info@^2.1.4: + version "2.8.9" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" + integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== + +ignore@^4.0.6: + version "4.0.6" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== + +ignore@^5.1.4, ignore@^5.1.8: + version "5.1.8" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.8.tgz#f150a8b50a34289b33e22f5889abd4d8016f0e57" + integrity sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw== + +import-fresh@^3.0.0, import-fresh@^3.2.1: + version "3.3.0" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" + integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== + dependencies: + parent-module "^1.0.0" + resolve-from "^4.0.0" + +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= + +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= + dependencies: + once "^1.3.0" + wrappy "1" + +inherits@2: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +internal-slot@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.3.tgz#7347e307deeea2faac2ac6205d4bc7d34967f59c" + integrity sha512-O0DB1JC/sPyZl7cIo78n5dR7eUSwwpYPiXRhTzNxZVAMUuB8vlnRFyLxdrVToks6XPLVnFfbzaVd5WLjhgg+vA== + dependencies: + get-intrinsic "^1.1.0" + has "^1.0.3" + side-channel "^1.0.4" + +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= + +is-bigint@^1.0.1: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" + integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== + dependencies: + has-bigints "^1.0.1" + +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" + integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-callable@^1.1.4, is-callable@^1.2.4: + version "1.2.4" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.4.tgz#47301d58dd0259407865547853df6d61fe471945" + integrity sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w== + +is-core-module@^2.2.0, is-core-module@^2.6.0: + version "2.7.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.7.0.tgz#3c0ef7d31b4acfc574f80c58409d568a836848e3" + integrity sha512-ByY+tjCciCr+9nLryBYcSD50EOGWt95c7tIsKTG1J2ixKKXPvF7Ej3AVd+UfDydAJom3biBGDBALaO79ktwgEQ== + dependencies: + has "^1.0.3" + +is-date-object@^1.0.1: + version "1.0.5" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" + integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== + dependencies: + has-tostringtag "^1.0.0" + +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= + +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + +is-glob@^4.0.0, is-glob@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.2.tgz#859fc2e731e58c902f99fcabccb75a7dd07d29d8" + integrity sha512-ZZTOjRcDjuAAAv2cTBQP/lL59ZTArx77+7UzHdWW/XB1mrfp7DEaVpKmZ0XIzx+M7AxfhKcqV+nMetUQmFifwg== + dependencies: + is-extglob "^2.1.1" + +is-negative-zero@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.1.tgz#3de746c18dda2319241a53675908d8f766f11c24" + integrity sha512-2z6JzQvZRa9A2Y7xC6dQQm4FSTSTNWjKIYYTt4246eMTJmIo0Q+ZyOsU66X8lxK1AbB92dFeglPLrhwpeRKO6w== + +is-number-object@^1.0.4: + version "1.0.6" + resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.6.tgz#6a7aaf838c7f0686a50b4553f7e54a96494e89f0" + integrity sha512-bEVOqiRcvo3zO1+G2lVMy+gkkEm9Yh7cDMRusKKu5ZJKPUYSJwICTKZrNKHA2EbSP0Tu0+6B/emsYNHZyn6K8g== + dependencies: + has-tostringtag "^1.0.0" + +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== + +is-regex@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" + integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-string@^1.0.5, is-string@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" + integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== + dependencies: + has-tostringtag "^1.0.0" + +is-symbol@^1.0.2, is-symbol@^1.0.3: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" + integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== + dependencies: + has-symbols "^1.0.2" + +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= + +js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-yaml@^3.13.1: + version "3.14.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" + integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + +json-parse-better-errors@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" + integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== + +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== + +json-schema-traverse@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" + integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== + +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= + +json5@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" + integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== + dependencies: + minimist "^1.2.0" + +levn@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.4.1.tgz#ae4562c007473b932a6200d403268dd2fffc6ade" + integrity sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ== + dependencies: + prelude-ls "^1.2.1" + type-check "~0.4.0" + +load-json-file@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" + integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= + dependencies: + graceful-fs "^4.1.2" + parse-json "^4.0.0" + pify "^3.0.0" + strip-bom "^3.0.0" + +locate-path@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" + integrity sha1-K1aLJl7slExtnA3pw9u7ygNUzY4= + dependencies: + p-locate "^2.0.0" + path-exists "^3.0.0" + +lodash.clonedeep@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" + integrity sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8= + +lodash.merge@^4.6.2: + version "4.6.2" + resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" + integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== + +lodash.truncate@^4.4.2: + version "4.4.2" + resolved "https://registry.yarnpkg.com/lodash.truncate/-/lodash.truncate-4.4.2.tgz#5a350da0b1113b837ecfffd5812cbe58d6eae193" + integrity sha1-WjUNoLERO4N+z//VgSy+WNbq4ZM= + +lru-cache@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" + integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== + dependencies: + yallist "^4.0.0" + +merge2@^1.3.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" + integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== + +micromatch@^4.0.0, micromatch@^4.0.4: + version "4.0.4" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.4.tgz#896d519dfe9db25fce94ceb7a500919bf881ebf9" + integrity sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg== + dependencies: + braces "^3.0.1" + picomatch "^2.2.3" + +minimatch@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== + dependencies: + brace-expansion "^1.1.7" + +minimist@^1.2.0: + version "1.2.5" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" + integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== + +ms@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" + integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= + +ms@2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@^2.1.1: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= + +normalize-package-data@^2.3.2: + version "2.5.0" + resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" + integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2 || 3 || 4 || 5" + validate-npm-package-license "^3.0.1" + +object-inspect@^1.11.0, object-inspect@^1.9.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.11.0.tgz#9dceb146cedd4148a0d9e51ab88d34cf509922b1" + integrity sha512-jp7ikS6Sd3GxQfZJPyH3cjcbJF6GZPClgdV+EFygjFLQ5FmW/dRUnTd9PQ9k0JhoNDabWFbpF1yCdSWCC6gexg== + +object-keys@^1.0.12, object-keys@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" + integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== + +object.assign@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" + integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== + dependencies: + call-bind "^1.0.0" + define-properties "^1.1.3" + has-symbols "^1.0.1" + object-keys "^1.1.1" + +object.values@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.4.tgz#0d273762833e816b693a637d30073e7051535b30" + integrity sha512-TnGo7j4XSnKQoK3MfvkzqKCi0nVe/D9I9IjwTNYdb/fxYHpjrluHVOgw0AF6jrRFGMPHdfuidR09tIDiIvnaSg== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.18.2" + +once@^1.3.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= + dependencies: + wrappy "1" + +optionator@^0.9.1: + version "0.9.1" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499" + integrity sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw== + dependencies: + deep-is "^0.1.3" + fast-levenshtein "^2.0.6" + levn "^0.4.1" + prelude-ls "^1.2.1" + type-check "^0.4.0" + word-wrap "^1.2.3" + +p-limit@^1.1.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" + integrity sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q== + dependencies: + p-try "^1.0.0" + +p-locate@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" + integrity sha1-IKAQOyIqcMj9OcwuWAaA893l7EM= + dependencies: + p-limit "^1.1.0" + +p-try@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" + integrity sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M= + +parent-module@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== + dependencies: + callsites "^3.0.0" + +parse-json@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" + integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= + dependencies: + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= + +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= + +path-key@^3.1.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" + integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== + +path-parse@^1.0.6: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + +path-type@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" + integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== + dependencies: + pify "^3.0.0" + +path-type@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" + integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== + +picomatch@^2.2.3: + version "2.3.0" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" + integrity sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw== + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" + integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= + +pkg-dir@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" + integrity sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s= + dependencies: + find-up "^2.1.0" + +pkg-up@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pkg-up/-/pkg-up-2.0.0.tgz#c819ac728059a461cab1c3889a2be3c49a004d7f" + integrity sha1-yBmscoBZpGHKscOImivjxJoATX8= + dependencies: + find-up "^2.1.0" + +prelude-ls@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" + integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== + +progress@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== + +punycode@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== + +queue-microtask@^1.2.2: + version "1.2.3" + resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" + integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== + +read-pkg-up@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-3.0.0.tgz#3ed496685dba0f8fe118d0691dc51f4a1ff96f07" + integrity sha1-PtSWaF26D4/hGNBpHcUfSh/5bwc= + dependencies: + find-up "^2.0.0" + read-pkg "^3.0.0" + +read-pkg@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" + integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= + dependencies: + load-json-file "^4.0.0" + normalize-package-data "^2.3.2" + path-type "^3.0.0" + +regexpp@^3.1.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2" + integrity sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg== + +require-from-string@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" + integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== + +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== + +resolve@^1.10.0, resolve@^1.20.0: + version "1.20.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" + integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== + dependencies: + is-core-module "^2.2.0" + path-parse "^1.0.6" + +reusify@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76" + integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw== + +rimraf@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-3.0.2.tgz#f1a5402ba6220ad52cc1282bac1ae3aa49fd061a" + integrity sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA== + dependencies: + glob "^7.1.3" + +run-parallel@^1.1.9: + version "1.2.0" + resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" + integrity sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA== + dependencies: + queue-microtask "^1.2.2" + +"semver@2 || 3 || 4 || 5": + version "5.7.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" + integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + +semver@^7.2.1, semver@^7.3.4, semver@^7.3.5: + version "7.3.5" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.5.tgz#0b621c879348d8998e4b0e4be94b3f12e6018ef7" + integrity sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ== + dependencies: + lru-cache "^6.0.0" + +shebang-command@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" + integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== + dependencies: + shebang-regex "^3.0.0" + +shebang-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" + integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== + +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + +slash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" + integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== + +slice-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-4.0.0.tgz#500e8dd0fd55b05815086255b3195adf2a45fe6b" + integrity sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ== + dependencies: + ansi-styles "^4.0.0" + astral-regex "^2.0.0" + is-fullwidth-code-point "^3.0.0" + +spdx-correct@^3.0.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" + integrity sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w== + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" + integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== + +spdx-expression-parse@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz#cf70f50482eefdc98e3ce0a6833e4a53ceeba679" + integrity sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q== + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.10" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.10.tgz#0d9becccde7003d6c658d487dd48a32f0bf3014b" + integrity sha512-oie3/+gKf7QtpitB0LYLETe+k8SifzsX4KixvpOsbI6S0kRiRQ5MKOio8eMSAKQ17N06+wdEOXRiId+zOxo0hA== + +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= + +string-width@^4.2.0: + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string.prototype.trimend@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/string.prototype.trimend/-/string.prototype.trimend-1.0.4.tgz#e75ae90c2942c63504686c18b287b4a0b1a45f80" + integrity sha512-y9xCjw1P23Awk8EvTpcyL2NIr1j7wJ39f+k6lvRnSMz+mz9CGz9NYPelDk42kOz6+ql8xjfK8oYzy3jAP5QU5A== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +string.prototype.trimstart@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/string.prototype.trimstart/-/string.prototype.trimstart-1.0.4.tgz#b36399af4ab2999b4c9c648bd7a3fb2bb26feeed" + integrity sha512-jh6e984OBfvxS50tdY2nRZnoC5/mLFKOREQfw8t5yytkoUsJRNxvI/E39qu1sD0OtWI3OC0XgKSmcWwziwYuZw== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + +strip-bom@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" + integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= + +strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" + integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== + +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== + dependencies: + has-flag "^3.0.0" + +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== + dependencies: + has-flag "^4.0.0" + +table@^6.0.9: + version "6.7.1" + resolved "https://registry.yarnpkg.com/table/-/table-6.7.1.tgz#ee05592b7143831a8c94f3cee6aae4c1ccef33e2" + integrity sha512-ZGum47Yi6KOOFDE8m223td53ath2enHcYLgOCjGr5ngu8bdIARQk6mN/wRMv4yMRcHnCSnHbCEha4sobQx5yWg== + dependencies: + ajv "^8.0.1" + lodash.clonedeep "^4.5.0" + lodash.truncate "^4.4.2" + slice-ansi "^4.0.0" + string-width "^4.2.0" + strip-ansi "^6.0.0" + +tapable@^2.2.0: + version "2.2.1" + resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" + integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== + +text-table@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= + +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== + dependencies: + is-number "^7.0.0" + +ts-loader@^9.2.6: + version "9.2.6" + resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.2.6.tgz#9937c4dd0a1e3dbbb5e433f8102a6601c6615d74" + integrity sha512-QMTC4UFzHmu9wU2VHZEmWWE9cUajjfcdcws+Gh7FhiO+Dy0RnR1bNz0YCHqhI0yRowCE9arVnNxYHqELOy9Hjw== + dependencies: + chalk "^4.1.0" + enhanced-resolve "^5.0.0" + micromatch "^4.0.0" + semver "^7.3.4" + +tsconfig-paths@^3.11.0: + version "3.11.0" + resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.11.0.tgz#954c1fe973da6339c78e06b03ce2e48810b65f36" + integrity sha512-7ecdYDnIdmv639mmDwslG6KQg1Z9STTz1j7Gcz0xa+nshh/gKDAHcPxRbWOsA3SPp0tXP2leTcY9Kw+NAkfZzA== + dependencies: + "@types/json5" "^0.0.29" + json5 "^1.0.1" + minimist "^1.2.0" + strip-bom "^3.0.0" + +tslib@^1.8.1: + version "1.14.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" + integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== + +tsutils@^3.21.0: + version "3.21.0" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" + integrity sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA== + dependencies: + tslib "^1.8.1" + +type-check@^0.4.0, type-check@~0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1" + integrity sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew== + dependencies: + prelude-ls "^1.2.1" + +type-fest@^0.20.2: + version "0.20.2" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.20.2.tgz#1bf207f4b28f91583666cb5fbd327887301cd5f4" + integrity sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ== + +typescript@^4.4.3: + version "4.4.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.3.tgz#bdc5407caa2b109efd4f82fe130656f977a29324" + integrity sha512-4xfscpisVgqqDfPaJo5vkd+Qd/ItkoagnHpufr+i2QCHBsNYp+G7UAoyFl8aPtx879u38wPV65rZ8qbGZijalA== + +unbox-primitive@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/unbox-primitive/-/unbox-primitive-1.0.1.tgz#085e215625ec3162574dc8859abee78a59b14471" + integrity sha512-tZU/3NqK3dA5gpE1KtyiJUrEB0lxnGkMFHptJ7q6ewdZ8s12QrODwNbhIJStmJkd1QDXa1NRA8aF2A1zk/Ypyw== + dependencies: + function-bind "^1.1.1" + has-bigints "^1.0.1" + has-symbols "^1.0.2" + which-boxed-primitive "^1.0.2" + +uri-js@^4.2.2: + version "4.4.1" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" + integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== + dependencies: + punycode "^2.1.0" + +v8-compile-cache@^2.0.3: + version "2.3.0" + resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" + integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== + +validate-npm-package-license@^3.0.1: + version "3.0.4" + resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" + integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== + dependencies: + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" + +which-boxed-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz#13757bc89b209b049fe5d86430e21cf40a89a8e6" + integrity sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg== + dependencies: + is-bigint "^1.0.1" + is-boolean-object "^1.1.0" + is-number-object "^1.0.4" + is-string "^1.0.5" + is-symbol "^1.0.3" + +which@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" + integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== + dependencies: + isexe "^2.0.0" + +word-wrap@^1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" + integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + +wrappy@1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= + +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== diff --git a/makefile b/makefile new file mode 100644 index 0000000..971655e --- /dev/null +++ b/makefile @@ -0,0 +1,71 @@ +jstest: + cd example && yarn add -D ../npm/esbuild-dev-server && yarn add -D ../npm/esbuild-dev-server-win32-x64 && yarn js-start + +gotest: + cd example && yarn go-start + +dts: + cd lib && yarn build + +build: + go run cmd/build/build.go + +build-all: + make build \ + build-win-32 \ + build-win-64 \ + build-win-arm-64 \ + build-linux-32 \ + build-linux-64 \ + build-linux-arm \ + build-linux-arm-64 \ + build-darwin-64 \ + build-darwin-arm-64 + +build-win-32: + GOOS=windows GOARCH=386 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver.exe npm/esbuild-dev-server-win32-x32 + +build-win-64: + GOOS=windows GOARCH=386 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver.exe npm/esbuild-dev-server-win32-x64 + +build-win-arm-64: + GOOS=windows GOARCH=arm64 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver.exe npm/esbuild-dev-server-win32-arm64 + +build-linux-32: + GOOS=linux GOARCH=386 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-linux-x32 + +build-linux-64: + GOOS=linux GOARCH=amd64 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-linux-x64 + +build-linux-arm: + GOOS=linux GOARCH=arm go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-linux-arm + +build-linux-arm-64: + GOOS=linux GOARCH=arm64 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-linux-arm64 + +build-darwin-64: + GOOS=darwin GOARCH=amd64 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-darwin-x64 + +build-darwin-arm-64: + GOOS=darwin GOARCH=arm64 go build -ldflags "-s -w" cmd/devserver/devserver.go + mv devserver npm/esbuild-dev-server-darwin-arm64 + +publish: + cd npm/esbuild-dev-server && npm publish + cd npm/esbuild-dev-server-win32-x32 && npm publish + cd npm/esbuild-dev-server-win32-x64 && npm publish + cd npm/esbuild-dev-server-win32-arm64 && npm publish + cd npm/esbuild-dev-server-linux-x32 && npm publish + cd npm/esbuild-dev-server-linux-x64 && npm publish + cd npm/esbuild-dev-server-linux-arm && npm publish + cd npm/esbuild-dev-server-linux-arm64 && npm publish + cd npm/esbuild-dev-server-darwin-x64 && npm publish + cd npm/esbuild-dev-server-darwin-arm64 && npm publish \ No newline at end of file diff --git a/npm/esbuild-dev-server-darwin-arm64/README.md b/npm/esbuild-dev-server-darwin-arm64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-darwin-arm64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-darwin-arm64/package.json b/npm/esbuild-dev-server-darwin-arm64/package.json new file mode 100644 index 0000000..115490d --- /dev/null +++ b/npm/esbuild-dev-server-darwin-arm64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-darwin-arm64", + "version": "0.3.0", + "description": "The Darwin arm 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "darwin" + ], + "cpu": [ + "arm64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-darwin-x64/README.md b/npm/esbuild-dev-server-darwin-x64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-darwin-x64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-darwin-x64/package.json b/npm/esbuild-dev-server-darwin-x64/package.json new file mode 100644 index 0000000..783e53e --- /dev/null +++ b/npm/esbuild-dev-server-darwin-x64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-darwin-x64", + "version": "0.3.0", + "description": "The Darwin 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "darwin" + ], + "cpu": [ + "x64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-linux-arm/README.md b/npm/esbuild-dev-server-linux-arm/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-linux-arm/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-linux-arm/package.json b/npm/esbuild-dev-server-linux-arm/package.json new file mode 100644 index 0000000..dfd285d --- /dev/null +++ b/npm/esbuild-dev-server-linux-arm/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-linux-arm", + "version": "0.3.0", + "description": "The Linux arm binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "linux" + ], + "cpu": [ + "arm" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-linux-arm64/README.md b/npm/esbuild-dev-server-linux-arm64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-linux-arm64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-linux-arm64/package.json b/npm/esbuild-dev-server-linux-arm64/package.json new file mode 100644 index 0000000..8de6ccf --- /dev/null +++ b/npm/esbuild-dev-server-linux-arm64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-linux-arm64", + "version": "0.3.0", + "description": "The Linux arm 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "linux" + ], + "cpu": [ + "arm64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-linux-x32/README.md b/npm/esbuild-dev-server-linux-x32/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-linux-x32/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-linux-x32/package.json b/npm/esbuild-dev-server-linux-x32/package.json new file mode 100644 index 0000000..0c0bd7a --- /dev/null +++ b/npm/esbuild-dev-server-linux-x32/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-linux-x32", + "version": "0.3.0", + "description": "The Linux 32-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "linux" + ], + "cpu": [ + "x32" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-linux-x64/README.md b/npm/esbuild-dev-server-linux-x64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-linux-x64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-linux-x64/package.json b/npm/esbuild-dev-server-linux-x64/package.json new file mode 100644 index 0000000..52190b0 --- /dev/null +++ b/npm/esbuild-dev-server-linux-x64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-linux-x64", + "version": "0.3.0", + "description": "The Linux 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "linux" + ], + "cpu": [ + "x64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-win32-arm64/README.md b/npm/esbuild-dev-server-win32-arm64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-win32-arm64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-win32-arm64/package.json b/npm/esbuild-dev-server-win32-arm64/package.json new file mode 100644 index 0000000..e955bbb --- /dev/null +++ b/npm/esbuild-dev-server-win32-arm64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-win32-arm64", + "version": "0.3.0", + "description": "The Windows arm 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "win32" + ], + "cpu": [ + "arm64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-win32-x32/README.md b/npm/esbuild-dev-server-win32-x32/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-win32-x32/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-win32-x32/package.json b/npm/esbuild-dev-server-win32-x32/package.json new file mode 100644 index 0000000..ab2684b --- /dev/null +++ b/npm/esbuild-dev-server-win32-x32/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-win32-x32", + "version": "0.3.0", + "description": "The Windows 32-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "win32" + ], + "cpu": [ + "ia32" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server-win32-x64/README.md b/npm/esbuild-dev-server-win32-x64/README.md new file mode 100644 index 0000000..fa3aa1d --- /dev/null +++ b/npm/esbuild-dev-server-win32-x64/README.md @@ -0,0 +1,3 @@ +# esbuild-dev-server + +> [esbuild-dev-server plugin](https://github.com/Falldot/esbuild-dev-server) allows you to start a local server with hot reloading with [Esbuild](https://esbuild.github.io/) diff --git a/npm/esbuild-dev-server-win32-x64/package.json b/npm/esbuild-dev-server-win32-x64/package.json new file mode 100644 index 0000000..2caa6c8 --- /dev/null +++ b/npm/esbuild-dev-server-win32-x64/package.json @@ -0,0 +1,37 @@ +{ + "name": "esbuild-dev-server-win32-x64", + "version": "0.3.0", + "description": "The Windows 64-bit binary for esbuild-dev-server", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "os": [ + "win32" + ], + "cpu": [ + "x64" + ], + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} diff --git a/npm/esbuild-dev-server/README.md b/npm/esbuild-dev-server/README.md new file mode 100644 index 0000000..da5aa65 --- /dev/null +++ b/npm/esbuild-dev-server/README.md @@ -0,0 +1,109 @@ +# esbuild-dev-server + +This plugin allows you to start a local server with hot reloading for [Esbuild](https://esbuild.github.io/) + +More community [plugins](https://github.com/esbuild/community-plugins) + +## Installation +`npm` +``` +npm i esbuild-dev-server -D +``` +`yarn` +``` +yarn add esbuild-dev-server -D +``` +`go` +``` +go get github.com/Falldot/esbuild-dev-server +``` +## Configuration + +- `options.port`, `string`: local server start port. +- `options.index`, `string`: path to index html file. +- `options.staticDir`, `string`: path to static files (js, css, img ...). +- `options.watchDir`, `string`: path to working directory. +- `options.onBeforeRebuild`, `() => void`: event before rebuild. +- `options.onAfterRebuild`, `() => void`: event after rebuild. + +## How to use? +### Node.js +`esbuild.config.js` +```js +const {build} = require("esbuild") +const esBuildDevServer = require("esbuild-dev-server") + +esBuildDevServer.start( + build({ + entryPoints: ["src/index.js"], + outdir: "dist", + incremental: true, + // and more options ... + }), + { + port: "8080", // optional, default: 8080 + watchDir: "src", // optional, default: "src" + index: "dist/index.html", // optional + staticDir: "dist", // optional + onBeforeRebuild: {}, // optional + onAfterRebuild: {}, // optional + } +) +``` +`package.json` +```json +"scripts": { + "dev": "node esbuild.config.js", +}, +``` +`dist/index.html` +```html + + + + + + + Document + + +
+ + + +``` +### Golang +`esbuild.config.go` +```go +package main + +import ( + devserver "github.com/Falldot/esbuild-dev-server" + "github.com/evanw/esbuild/pkg/api" +) + +func main() { + devserver.Start( + api.Build(api.BuildOptions{ + EntryPoints: []string{"src/index.js"}, + Outdir: "dist", + Incremental: true, + // and more options ... + }), + devserver.Options{ + Port: "8080", // optional, default: 8080 + WatchDir: "src", // optional, default: "src" + Index: "dist/index.html", // optional + StaticDir: "dist", // optional + OnBeforeRebuild: func() {}, // optional + OnAfterRebuild: func() {}, // optional + }, + ) +} +``` +`package.json` +```json +"scripts": { + "dev": "go esbuild.config.go", +}, +``` \ No newline at end of file diff --git a/npm/esbuild-dev-server/package.json b/npm/esbuild-dev-server/package.json new file mode 100644 index 0000000..546cf60 --- /dev/null +++ b/npm/esbuild-dev-server/package.json @@ -0,0 +1,44 @@ +{ + "name": "esbuild-dev-server", + "version": "0.3.0", + "description": "An fast JavaScript hot dev local server.", + "types": "lib/esbuild-dev-server.d.ts", + "main": "lib/esbuild-dev-server.js", + "repository": { + "type": "git", + "url": "git+https://github.com/Falldot/esbuild-dev-server.git" + }, + "bugs": { + "url": "https://github.com/Falldot/esbuild-dev-server/issues" + }, + "optionalDependencies": { + "esbuild-dev-server-linux-x32": "0.3.0", + "esbuild-dev-server-linux-x64": "0.3.0", + "esbuild-dev-server-linux-arm": "0.3.0", + "esbuild-dev-server-linux-arm64": "0.3.0", + "esbuild-dev-server-win32-x32": "0.3.0", + "esbuild-dev-server-win32-x64": "0.3.0", + "esbuild-dev-server-win32-arm64": "0.3.0", + "esbuild-dev-server-darwin-x64": "0.3.0", + "esbuild-dev-server-darwin-arm64": "0.3.0" + }, + "keywords": [ + "esbuild-dev-server", + "esbuild", + "dev", + "server", + "live", + "live server", + "dev server", + "node", + "javascript", + "typescript", + "hot", + "reload", + "hot reload", + "serve", + "web" + ], + "author": "Vladislav Fedotov", + "license": "MIT" +} \ No newline at end of file