aboutsummaryrefslogtreecommitdiffstats
path: root/src/data/var/acceptData.js
blob: 6b154c5b3e1e03430ab7ed6f48da0c7f8413791e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/**
 * Determines whether an object can have data
 */
export default function( owner ) {

	// Accepts only:
	//  - Node
	//    - Node.ELEMENT_NODE
	//    - Node.DOCUMENT_NODE
	//  - Object
	//    - Any
	return owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType );
}