set:leading() returns the nodes in one node-set that come before the first node in the other node-set.

Syntax

set:leading(nodeSet1, nodeSet2)

Parameters

nodeSet1
The node set to find nodes in that precede the first node in the second node set.
nodeSet2
The node set to compare against.

Returns

A node-set containing the nodes from nodeSet1 whose values precede the first node in nodeSet2.

Note: If the first node in nodeSet2 isn't contained in nodeSet1, an empty set is returned. If nodeSet2 is empty, then the result is nodeSet1.

Specifications

EXSLT - SET:LEADING

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidEdge MobileFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
set:leading()Chrome ? Edge ? Firefox Full support 3IE ? Opera ? Safari ? WebView Android ? Chrome Android ? Edge Mobile ? Firefox Android Full support 4Opera Android ? Safari iOS ? Samsung Internet Android ?

Legend

Full support  
Full support
Compatibility unknown  
Compatibility unknown

Document Tags and Contributors

Contributors to this page: ExE-Boss, mdnwebdocs-bot, Sheppy, trevorh, Mgjbot, Fredchat
Last updated by: ExE-Boss,