aboutsummaryrefslogtreecommitdiff
path: root/test/bundler (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-09-29Implement virtual module support in `Bun.plugin` (#6167)Gravatar Jarred Sumner 1-0/+23
* Add support for `build.module` in `Bun.plugin` * Another test * Update docs * Update isBuiltinModule.cpp --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Co-authored-by: Dylan Conway <dylan.conway567@gmail.com>
2023-09-28fix decorator testsGravatar Dylan Conway 1-518/+1244
2023-09-27fix typescript metadata for import identifiers (#6130)Gravatar Dylan Conway 1-0/+34
* handle import identifiers * a test * handle dot case
2023-09-27update snapshotsGravatar Dylan Conway 1-3/+3
2023-09-20add `emitDecoratorMetadata` (#5777)Gravatar Dylan Conway 1-0/+505
* some progess * needs more tests * make tests easier to debug * get metadata for constructor arg decorators * fix some things * merge `emitDecoratorMetadata` option * remove `^` * bundler tests and get option from tsconfig earlier * remove spaces * fix tests
2023-09-15fix(bundler): Add a space before minified require (#5521)Gravatar David Hewitt 1-0/+21
Fixes #5501
2023-09-12Fix bug with bun build --compile (#5102)Gravatar Jarred Sumner 1-0/+3
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-24Disable minifying "str".length until ↵Gravatar Jarred Sumner 1-1/+3
https://github.com/oven-sh/bun/issues/4217 is fixed
2023-08-23Fix `<const T>() =>` (#4278)bun-v0.8.0Gravatar dave caruso 1-0/+70
2023-08-22fix yield (#4264)Gravatar dave caruso 1-0/+16
2023-08-21Fix(bundler): allow generating exe file in nested path. (#4226)Gravatar Ai Hoshino 1-1/+40
* Fix(bundler): allow generating binary file in nested path. Close: #4195 * Add read flag for fd. * refactor
2023-08-20Fix(bundler): use different alias mappings based on the target. (#4163)Gravatar Ai Hoshino 2-0/+31
* Fix(bundler): use different alias mappings based on the target. Close: #3844 * chore: reduce duplicated code. * chore: split to two separate ComptimeStringMap.
2023-08-11Support TypeScript's `export type * as Foo from 'bar'` (#4125)Gravatar Jarred Sumner 1-0/+12
* [TypeScript] Support `export type * as Foo from 'bar'` * Update js_parser.zig --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-03allow bundling builtins for browser (#3959)Gravatar Dylan Conway 1-0/+36
* Update resolver.zig * bundle resolve error for non-existent builtins * tests
2023-07-24Skip testGravatar Jarred Sumner 1-0/+3
2023-07-23Fixes #3764Gravatar Jarred Sumner 1-0/+18
2023-07-21string escape edgecase (#3717)bun-v0.7.0Gravatar Dylan Conway 1-4/+4
* fix edgecase when joining rope strings with backtick * bonus bugfix in ts decorator * Update transpiler.test.js * Fix test --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Co-authored-by: Jarred Sumner <jarred@jarredsumner.com>
2023-07-19Fix browser bundled string_decoder (#3693)Gravatar dave caruso 1-0/+16
* Fix #3660 * doc fix
2023-07-17package json `main` field extension order (#3664)Gravatar Dylan Conway 1-0/+76
2023-07-07Unmark as TODOGravatar Jarred Sumner 1-2/+0
2023-07-07Update testGravatar Jarred Sumner 1-6/+7
2023-07-06add `[dir]` to defaultGravatar Dylan Conway 1-2/+2
2023-06-29[bundler] avoid printing unnecessary declarations (#3456)Gravatar Dylan Conway 1-0/+71
* skip declarations without values * tests * deoptimize cjs when decls are needed
2023-06-28use main field over module for runtime (#3448)Gravatar Dylan Conway 1-0/+200
* use main field over module for runtime * move flag to `Resolver` * set `prefer_module_field` in `initWithModuleGraph`
2023-06-24Rewrite Bun's runtime CommonJS loader (#3379)Gravatar Jarred Sumner 1-7/+10
* wip changes for CommonJS * this rewrite is almost complete * even more code * wip * Remove usages of `import.meta.require` from builtins * Remove usages of require * Regenerate * :scissors: builtin rewrite commonjs in printer * Use lazy custom getters for import.meta * fixups * Remove depd * ugh * still crashing * fixup undici * comment out import.meta.require.resolve temporarily not a real solution but it stops the crashes * Redo import.meta.primordials * Builtins now have a `builtin://` protocol in source origin * Seems to work? * Finsih getting rid of primordials * switcharoo * No more function * just one more bug * Update launch.json * Implement `require.main` * :scissors: * Bump WebKit * Fixup import cycles * Fixup improt cycles * export more things * Implement `createCommonJSModule` builtin * More exports * regenerate * i broke some stuff * some of these tests work now * We lost the encoding * Sort of fix zlib * Sort of fix util * Update events.js * bump * bump * bump * Fix missing export in fs * fix some bugs with builtin esm modules (stream, worker_threads, events). its not perfect yet. * fix some other internal module bugs * oops * fix some extra require default stuff * uncomment this file but it crsahes on my machine * tidy code here * fixup tls exports * make simdutf happier * Add hasPrefix binding * Add test for `require.main` * Fix CommonJS evaluation order race condition * Make node:http load faster * Add missing exports to tls.js * Use the getter * Regenerate builtins * Fix assertion failure in Bun.write() * revamp dotEnv parser (#3347) - fixes `strings.indexOfAny()` - fixes OOB array access fixes #411 fixes #2823 fixes #3042 * fix tests for `expect()` (#3384) - extend test job time-out for `darwin-aarch64` * `expect().resolves` and `expect().rejects` (#3318) * Move expect and snapshots to their own files * expect().resolves and expect().rejects * Fix promise being added to unhandled rejection list * Handle timeouts in expect(<promise>) * wip merge * Fix merge issue --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com> Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> * fixup min/memcopy (#3388) * Fix crash in builtins * Don't attempt to evaluate modules with no source code * Update WebCoreJSBuiltins.cpp * Update WebCoreJSBuiltins.cpp * Update WebCoreJSBuiltins.cpp * Fix crash * cleanup * Fix test cc @paperdave * Fixup Undici * Fix issue in node:http * Create util-deprecate.mjs * Fix several bugs * Use the identifier * Support error.code in `util.deprecate` * make the CJs loader slightly more resilient * Update WebCoreJSBuiltins.cpp * Fix macros --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Co-authored-by: dave caruso <me@paperdave.net> Co-authored-by: Alex Lam S.L <alexlamsl@gmail.com> Co-authored-by: Ashcon Partovi <ashcon@partovi.net> Co-authored-by: Ciro Spaciari <ciro.spaciari@gmail.com>
2023-06-20record jsx factory symbols in classic mode (#3360)Gravatar Dylan Conway 2-1/+77
* record jsx factory symbols * merge factory/fragment when more than one part * update test * use existing functions, use, `memberListToComponentsIfDifferent` * missing file * fix defaults
2023-06-16don't remove const if referenced before declaration (#3337)Gravatar Dylan Conway 1-0/+42
2023-06-12handle unwrapping `require` in any expression (#3292)Gravatar Dylan Conway 1-0/+64
2023-06-09Fixes #3206 (#3262)Gravatar Jarred Sumner 1-0/+3
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-06-05add a test for lodash-es (#3217)Gravatar dave caruso 3-1/+64
* add bundling tests for lodash-es * add isBuffer tests
2023-06-03Add test case (#3186)Gravatar dave caruso 1-0/+27
2023-06-02[bundler] fix json imports, undo some todosGravatar Dylan Conway 3-10/+4
2023-06-02use NODE_ENV for react-jsx or react-jsxdev (#3184)Gravatar Dylan Conway 2-6/+122
2023-06-02Update macro/test docs (#3180)Gravatar Colin McDonnell 1-0/+28
* Add test and fix plugin type * Update docs and config pages
2023-06-02continue if import is standalone (#3178)Gravatar Dylan Conway 1-3/+0
2023-06-01mark currently known test fails as `.todo` (#3052)Gravatar dave caruso 19-202/+253
* start this * commit * mark all failing tests as todo * fasdfad * bundler tests * tests * adjust failing tests to todo * comment out some more tests * png as test
2023-05-29Rename this file so we know what it isGravatar Jarred Sumner 1-0/+0
2023-05-25update jsx test for classic runtimeGravatar Dylan Conway 1-1/+2
2023-05-24fix setting `jsxImportSource`, `jsxFactory`, and `jsxFragmentFactory` (#3057)Gravatar Dylan Conway 1-43/+163
* default automatic, merge jsx flags from multiple tsconfigs * use entire package name * some tests * more tests
2023-05-21Fix testGravatar Jarred Sumner 1-10/+10
2023-05-19resolve rope string for multipart template (#2963)Gravatar Dylan Conway 1-1/+29
* resolve rope for multipart template * fix tests * clone template part if it is `e_string` and folded * clone string only * don't clone data again
2023-05-19Add tests for `--compile` tests (#2901)Gravatar dave caruso 4-112/+300
* add compile test support * add react ssr test * add tests * Fix flaky compile test @paperdave we can't pass a non-zero port or it will be flaky --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com> Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-05-18Fixes #2946 (#2949)Gravatar Jarred Sumner 1-0/+43
* Fixes #2946 * Update string_mutable.zig * Fixes #2948 --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-05-18Fixes #2942 (#2947)Gravatar Jarred Sumner 1-0/+140
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-05-18use raw template contents for tagged templates (#2937)Gravatar Dylan Conway 1-2/+1
* use raw template contents when tagged * use union for template contents * pointer to cooked contents * raw if suffix * fix and don't skip test
2023-05-17do not fail bundles on warnings (#2920)Gravatar dave caruso 4-26/+60
2023-05-16resolve rope before pushing to previous string (#2909)Gravatar Dylan Conway 1-0/+52
2023-05-16Fix segfault on passing undefined to bun.build (#2902)Gravatar dave caruso 1-0/+10
2023-05-15handle printing missing expressions and add tests (#2872)Gravatar Dylan Conway 2-2/+129
* handle missing expressions and add tests * minify missing expression blocks in parser
2023-05-15bundler testing (#2886)Gravatar dave caruso 11-122/+2008
* bundler testing * add requireVarThenExport test * work towards adding more esbuild tests * tests * remove this file