mirror of
https://github.com/denoland/deno.git
synced 2024-11-22 15:06:54 -05:00
added mjs files for default fmt (#6134)
This commit is contained in:
parent
79d9cf52d0
commit
93175b7a79
1 changed files with 3 additions and 1 deletions
|
@ -193,7 +193,7 @@ fn is_supported(path: &Path) -> bool {
|
|||
.and_then(|e| e.to_str())
|
||||
.map(|e| e.to_lowercase());
|
||||
if let Some(ext) = lowercase_ext {
|
||||
ext == "ts" || ext == "tsx" || ext == "js" || ext == "jsx"
|
||||
ext == "ts" || ext == "tsx" || ext == "js" || ext == "jsx" || ext == "mjs"
|
||||
} else {
|
||||
false
|
||||
}
|
||||
|
@ -293,6 +293,8 @@ fn test_is_supported() {
|
|||
assert!(is_supported(Path::new("foo.TSX")));
|
||||
assert!(is_supported(Path::new("foo.JS")));
|
||||
assert!(is_supported(Path::new("foo.JSX")));
|
||||
assert!(is_supported(Path::new("foo.mjs")));
|
||||
assert!(!is_supported(Path::new("foo.mjsx")));
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
|
|
Loading…
Reference in a new issue