4 ms·
> the / in an XPath expression plays the same role as the > in a CSS selector: The `/` in an XPath expression is probably a better match for the space in CSS s
by masklinn 13y ago
> the / in an XPath expression plays the same role as the > in a CSS selector:
The `/` in an XPath expression is probably a better match for the space in CSS selectors.
- mmastrac 13y agoI think you are thinking of "//", which acts like the space (ie: any number of children).
- masklinn 13y agoNo, that's just a difference in default axis. I mean that `/` is a separator between traversal expressions, much like whitespace in CSS selectors.
- mmastrac 13y agoAh yeah, I understand what you mean now. XPath's `/` is something like a token that means "separate these two things". In CSS the separation between segments is the zero or more whitespace characters that live between the parts of the selector.