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

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions dist/debug.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/debug.js.map

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions dist/estrella.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/estrella.js.map

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions dist/watch.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/watch.js.map

Large diffs are not rendered by default.

519 changes: 505 additions & 14 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"node": ">=12.0.0"
},
"dependencies": {
"esbuild": "^0.11.0"
"esbuild": "^0.15.0"
},
"optionalDependencies": {
"fsevents": "~2.3.1"
Expand All @@ -48,6 +48,6 @@
"chokidar": "^3.5.1",
"miniglob": "^0.1.2",
"source-map-support": "^0.5.19",
"typescript": "^4.2.3"
"typescript": "^4.7.4"
}
}
19 changes: 15 additions & 4 deletions src/typeinfo.ts
Original file line number Diff line number Diff line change
@@ -1,37 +1,48 @@
// Do not edit. Generated by build.js

export const esbuild = {
version: "0.11.20",
version: "0.15.5",
BuildOptions: new Set([
"sourcemap" , // boolean | 'inline' | 'external' | 'both'
"sourcemap" , // boolean | 'linked' | 'inline' | 'external' | 'both'
"legalComments" , // 'none' | 'inline' | 'eof' | 'linked' | 'external'
"sourceRoot" , // string
"sourcesContent" , // boolean
"format" , // Format
"globalName" , // string
"target" , // string | string[]
"supported" , // Record<string, boolean>
"platform" , // Platform
"mangleProps" , // RegExp
"reserveProps" , // RegExp
"mangleQuoted" , // boolean
"mangleCache" , // Record<string, string | false>
"drop" , // Drop[]
"minify" , // boolean
"minifyWhitespace" , // boolean
"minifyIdentifiers" , // boolean
"minifySyntax" , // boolean
"charset" , // Charset
"treeShaking" , // TreeShaking
"treeShaking" , // boolean
"ignoreAnnotations" , // boolean
"jsx" , // 'transform' | 'preserve' | 'automatic'
"jsxFactory" , // string
"jsxFragment" , // string
"jsxImportSource" , // string
"jsxDev" , // boolean
"define" , // { [key: string]: string; }
"pure" , // string[]
"keepNames" , // boolean
"color" , // boolean
"logLevel" , // LogLevel
"logLimit" , // number
"logOverride" , // Record<string, LogLevel>
"bundle" , // boolean
"splitting" , // boolean
"preserveSymlinks" , // boolean
"outfile" , // string
"metafile" , // boolean
"outdir" , // string
"outbase" , // string
"platform" , // Platform
"external" , // string[]
"loader" , // { [ext: string]: Loader; }
"resolveExtensions" , // string[]
Expand Down
4 changes: 2 additions & 2 deletions test/cli-direct/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ _clean

_test "should write to outfile"
"$estrella" "-outfile=$outfile" main.ts -quiet
expect='console.log("Hello world")'
expect='"use strict";console.log("Hello world")'
actual=$(cat "$outfile")
if [[ "$("$estrella" main.ts)" != "$expect"* ]]; then
_fail "Unexpected output to $outfile. Expected [${expect}*] but got [$actual]"
Expand All @@ -50,7 +50,7 @@ echo "PASS"

_test "Should print to stdout when no outfile is given."
# Also there should be no "Wrote" log message.
expect='console.log("Hello world")'
expect='"use strict";console.log("Hello world")'
actual=$("$estrella" main.ts)
if [[ "$actual" != "$expect"* ]]; then
_fail "Unexpected output to stdout. Expected [${expect}*] but got [$actual]"
Expand Down
2 changes: 1 addition & 1 deletion test/issue-22-esbuildmeta/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ for i in {1..25}; do
else
sleep 1
fi
if [ -f out.log ] && grep -q "main.js:1:9: error: No matching export" out.log; then
if [ -f out.log ] && grep -q "No matching export in \"lib.js\" for import \"nonexisting\"" out.log; then
rm -f out.*
kill $pid && exit 0
echo "FAIL: estrella process exited prematurely" >&2
Expand Down
2 changes: 1 addition & 1 deletion test/tempfile-output/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ if ("TEST_OUTPUT_TO_STDOUT" in process.env) {
return
}
// console.log("result.map:", JSON.parse(result.map))
if (result.js.trim() != `console.log("a");`) {
if (result.js.trim() != `"use strict";console.log("a");`) {
fail("unexpected result.js:", result.js)
}
try {
Expand Down
2 changes: 1 addition & 1 deletion test/tempfile-output/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ node build.js

# test 2/2 -- stout output
OUTPUT=$(TEST_OUTPUT_TO_STDOUT=1 node build.js)
if [ "$OUTPUT" != 'console.log("a");' ]; then
if [ "$OUTPUT" != '"use strict";console.log("a");' ]; then
echo "unexpected output on stdout: $OUTPUT" >&2
exit 1
fi
Expand Down
4 changes: 2 additions & 2 deletions test/watch/test-cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ p.stdout.on('data', (data) => {
// file system actually being watched.
// To work around this, we sleep for a long enough time so that it is very likely to work.
setTimeout(()=>{
assertOutFileContent(/^console\.log\(1\)/)
assertOutFileContent(/^\"use strict\";console\.log\(1\)/)
writeInFile("console.log(2)")
},20)
break
Expand All @@ -72,7 +72,7 @@ p.stdout.on('data', (data) => {

case 4:
assertStdout(/^Wrote /i)
assertOutFileContent(/^console\.log\(2\)/)
assertOutFileContent(/^\"use strict\";console\.log\(2\)/)
expectedExit = true
process.exit(0)
break
Expand Down
6 changes: 3 additions & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
"moduleResolution": "node",
"allowJs": true,
"module": "esnext",
"target": "es2017",
"target": "es2018",
"baseUrl": "src",
"rootDirs": ["src"],
"outDir": "dist",
"outDir": "dist"
},
"files": [
"src/global.ts",
"src/estrella.js",
"src/debug/debug.ts",
"src/watch/watch.ts",
"src/watch/watch.ts"
]
}