-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into fix/444/reused-instances
- Loading branch information
Showing
10 changed files
with
516 additions
and
274 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
[build] | ||
ignore = "./scripts/docs-check.sh" | ||
publish = "docs/.vitepress/dist" | ||
command = "yarn run docs:build" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
diff --git a/node_modules/vite/dist/node/build/index.js b/node_modules/vite/dist/node/build/index.js | ||
index 923d0ea..7155e48 100644 | ||
--- a/node_modules/vite/dist/node/build/index.js | ||
+++ b/node_modules/vite/dist/node/build/index.js | ||
@@ -351,7 +351,7 @@ async function build(options) { | ||
console.log(`Build completed in ${((Date.now() - start) / 1000).toFixed(2)}s.\n`); | ||
} | ||
// stop the esbuild service after each build | ||
- esbuildService_1.stopService(); | ||
+ await esbuildService_1.stopService(); | ||
return { | ||
assets: output, | ||
html: indexHtml | ||
diff --git a/node_modules/vite/dist/node/esbuildService.js b/node_modules/vite/dist/node/esbuildService.js | ||
index 0d5d11b..2caf9e3 100644 | ||
--- a/node_modules/vite/dist/node/esbuildService.js | ||
+++ b/node_modules/vite/dist/node/esbuildService.js | ||
@@ -33,16 +33,19 @@ function resolveJsxOptions(options = 'vue') { | ||
} | ||
exports.resolveJsxOptions = resolveJsxOptions; | ||
// lazy start the service | ||
-let _service; | ||
-const ensureService = async () => { | ||
- if (!_service) { | ||
- _service = await esbuild_1.startService(); | ||
+let _servicePromise; | ||
+const ensureService = () => { | ||
+ if (!_servicePromise) { | ||
+ _servicePromise = esbuild_1.startService(); | ||
} | ||
- return _service; | ||
+ return _servicePromise; | ||
}; | ||
-exports.stopService = () => { | ||
- _service && _service.stop(); | ||
- _service = undefined; | ||
+exports.stopService = async () => { | ||
+ if (_servicePromise) { | ||
+ const service = await _servicePromise | ||
+ service.stop(); | ||
+ _servicePromise = undefined; | ||
+ } | ||
}; | ||
// transform used in server plugins with a more friendly API | ||
exports.transform = async (src, request, options = {}, jsxOption) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/bin/bash | ||
|
||
# check if doc files changes for netlify | ||
# needed because we cannot use && in netlify.toml | ||
|
||
git diff --quiet 'HEAD^' HEAD ./docs/ && ! git diff 'HEAD^' HEAD ./yarn.lock | grep --quiet vite |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.