@@ -420,6 +420,11 @@ pub struct BookConfig {
420
420
pub description : Option < String > ,
421
421
/// Location of the book source relative to the book's root directory.
422
422
pub src : PathBuf ,
423
+ /// Does this book support more than one language?
424
+ // TODO: Remove this field in 0.5, it is unused:
425
+ // https://github.com/rust-lang/mdBook/issues/2636
426
+ #[ serde( skip_serializing) ]
427
+ pub multilingual : bool ,
423
428
/// The main language of the book.
424
429
pub language : Option < String > ,
425
430
/// The direction of text in the book: Left-to-right (LTR) or Right-to-left (RTL).
@@ -434,6 +439,7 @@ impl Default for BookConfig {
434
439
authors : Vec :: new ( ) ,
435
440
description : None ,
436
441
src : PathBuf :: from ( "src" ) ,
442
+ multilingual : false ,
437
443
language : Some ( String :: from ( "en" ) ) ,
438
444
text_direction : None ,
439
445
}
@@ -817,6 +823,7 @@ mod tests {
817
823
title = "Some Book"
818
824
authors = ["Michael-F-Bryan <[email protected] >"]
819
825
description = "A completely useless book"
826
+ multilingual = true
820
827
src = "source"
821
828
language = "ja"
822
829
@@ -855,6 +862,7 @@ mod tests {
855
862
title : Some ( String :: from ( "Some Book" ) ) ,
856
863
authors : vec ! [ String :: from
( "Michael-F-Bryan <[email protected] >" ) ] ,
857
864
description : Some ( String :: from ( "A completely useless book" ) ) ,
865
+ multilingual : true ,
858
866
src : PathBuf :: from ( "source" ) ,
859
867
language : Some ( String :: from ( "ja" ) ) ,
860
868
text_direction : None ,
0 commit comments