Skip to content

Commit

Permalink
inline wanted-extensions
Browse files Browse the repository at this point in the history
Not 100% convinced yet, but seems cleaner so far.
  • Loading branch information
RobinMalfait committed May 2, 2023
1 parent 6ab1b0d commit 879c124
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 20 deletions.
15 changes: 0 additions & 15 deletions oxide/crates/core/src/fixtures/wanted-extensions.txt

This file was deleted.

9 changes: 4 additions & 5 deletions oxide/crates/core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,10 @@ pub fn resolve_content_paths(args: ContentPathInfo) -> Vec<String> {
let static_direct_folder_indentifiers = vec!["public"];

// A list of known extensions + a list of extensions we found in the project.
let mut found_extensions = FxHashSet::from_iter(
include_str!("fixtures/wanted-extensions.txt")
.trim()
.lines(),
);
let mut found_extensions = FxHashSet::from_iter(vec![
"js", "ts", "jsx", "tsx", "mjs", "mts", "cjs", "cts", "html", "php", "vue", "svelte",
"astro", "md", "mdx",
]);

// A list of direct folders, from the root, where we can use globs to watch all files.
let mut direct_folders = FxHashSet::default();
Expand Down

0 comments on commit 879c124

Please sign in to comment.