Boolean ng.Element.is_child_of (Mixed elm) vs. 1.1.0 Full+Lite

Checks if the main HTML Element is a child of the given elm HTML Element.

Parameters

Mixed elm Required vs. 1.1.0 Full+Lite
The parent HTML Element. It can one of the following:
  • String: the parent HTML Element ID.
  • HTML Element.

Return

Boolean Required vs. 1.1.0 Full+Lite
True if the current HTML Element is a child of the given elm HTML Element. False otherwise.

Examples

Using ng.Element.is_child_of
Demo:
First Child
Second Child
This is another div

Checking if "main_div" is the parent of:

API Menu