add amd support
optionally pass elements to be checked as parameter on call
Merge branch 'feature-spans-param'