Skip to content

Commit

Permalink
Merge branch 'add/test-enable-swcloader' of github.com:timneutkens/ne…
Browse files Browse the repository at this point in the history
…xt.js into add/test-enable-swcloader
  • Loading branch information
timneutkens committed Oct 23, 2021
2 parents 37f7883 + 2a0dda0 commit bcc2a3b
Show file tree
Hide file tree
Showing 12 changed files with 37 additions and 28 deletions.
5 changes: 4 additions & 1 deletion packages/next/build/swc/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ pub struct TransformOptions {
#[serde(default)]
pub pages_dir: Option<PathBuf>,

#[serde(default)]
pub is_page_file: bool,

#[serde(default)]
pub is_development: bool,
}
Expand All @@ -79,7 +82,7 @@ pub fn custom_before_pass(name: &FileName, opts: &TransformOptions) -> impl Fold
amp_attributes::amp_attributes(),
next_dynamic::next_dynamic(name.clone(), opts.pages_dir.clone()),
Optional::new(
page_config::page_config(opts.is_development),
page_config::page_config(opts.is_development, opts.is_page_file),
!opts.disable_page_config
)
)
Expand Down
Loading

0 comments on commit bcc2a3b

Please sign in to comment.