mirror of
https://github.com/oven-sh/bun
synced 2026-02-02 15:08:46 +00:00
Fix origin
Former-commit-id: 1abca35a1e83a1ccb2cd39bc04568eb9bc170b15
This commit is contained in:
@@ -27,7 +27,7 @@ pub const DefaultSpeedyDefines = struct {
|
||||
pub fn configureTransformOptionsForSpeedyVM(allocator: *std.mem.Allocator, _args: Api.TransformOptions) !Api.TransformOptions {
|
||||
var args = _args;
|
||||
|
||||
args.serve = false;
|
||||
// args.serve = false;
|
||||
args.write = false;
|
||||
args.resolve = Api.ResolveMode.lazy;
|
||||
args.generate_node_module_bundle = false;
|
||||
|
||||
@@ -719,6 +719,10 @@ pub const BundleOptions = struct {
|
||||
if (transform.serve orelse false) {
|
||||
opts.preserve_extensions = true;
|
||||
opts.append_package_version_in_query_string = true;
|
||||
if (opts.origin.len == 0) {
|
||||
opts.origin = "/";
|
||||
}
|
||||
|
||||
opts.resolve_mode = .lazy;
|
||||
var _dirs = [_]string{transform.public_dir orelse opts.public_dir};
|
||||
opts.public_dir = try fs.absAlloc(allocator, &_dirs);
|
||||
|
||||
Reference in New Issue
Block a user