absolute_parent() — tailwindcss Function Reference
Architecture documentation for the absolute_parent() function in dir.rs from the tailwindcss codebase.
Entity Profile
Dependency Diagram
graph TD ac45ed16_deea_3b31_5d2e_af6f2cfcd46f["absolute_parent()"] 1d8e185d_2d17_16a2_e6da_31f5e5c71648["tmpdir()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| 1d8e185d_2d17_16a2_e6da_31f5e5c71648 b23c536f_df64_0c16_7823_c6333e8bd192["mkdirp()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| b23c536f_df64_0c16_7823_c6333e8bd192 a3791d58_6294_cb66_0418_5756e23761fd["path()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| a3791d58_6294_cb66_0418_5756e23761fd b531cfc0_8a2c_1d41_6f18_1d84e771a9ef["wfile()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| b531cfc0_8a2c_1d41_6f18_1d84e771a9ef 386bbf62_59b6_b5e0_c202_c2ecee5729ec["build()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| 386bbf62_59b6_b5e0_c202_c2ecee5729ec 7f3cd9fa_fc0e_11d8_c82c_d766c339923a["add_child()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| 7f3cd9fa_fc0e_11d8_c82c_d766c339923a 22918057_f3e8_c59b_6372_a4375af46acd["matched()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| 22918057_f3e8_c59b_6372_a4375af46acd 53fcda14_433d_b98d_8ccd_5c1f3bb4d3c8["add_parents()"] ac45ed16_deea_3b31_5d2e_af6f2cfcd46f -->|calls| 53fcda14_433d_b98d_8ccd_5c1f3bb4d3c8 style ac45ed16_deea_3b31_5d2e_af6f2cfcd46f fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
crates/ignore/src/dir.rs lines 1179–1199
fn absolute_parent() {
let td = tmpdir();
mkdirp(td.path().join(".git"));
mkdirp(td.path().join("foo"));
wfile(td.path().join(".gitignore"), "bar");
// First, check that the parent gitignore file isn't detected if the
// parent isn't added. This establishes a baseline.
let ig0 = IgnoreBuilder::new().build();
let (ig1, err) = ig0.add_child(td.path().join("foo"));
assert!(err.is_none());
assert!(ig1.matched("bar", false).is_none());
// Second, check that adding a parent directory actually works.
let ig0 = IgnoreBuilder::new().build();
let (ig1, err) = ig0.add_parents(td.path().join("foo"));
assert!(err.is_none());
let (ig2, err) = ig1.add_child(td.path().join("foo"));
assert!(err.is_none());
assert!(ig2.matched("bar", false).is_ignore());
}
Domain
Subdomains
Source
Frequently Asked Questions
What does absolute_parent() do?
absolute_parent() is a function in the tailwindcss codebase.
What does absolute_parent() call?
absolute_parent() calls 8 function(s): add_child, add_parents, build, matched, mkdirp, path, tmpdir, wfile.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free