layer.classList < ClassList object>
A list of class attributed for the layer. Also contains methods to add, remove, toggle and check for classes. For a full reference, see this overview.
译:认为该层的类的列表。 还包含方法来添加、移除切换和检查类。为充分引用,请参阅本概述。
layerA = new Layer
# Add the class .red
layerA.classList.add("red")
# Remove the class .red
layerA.classList.remove("red")
# Toggle the class .red
layerA.classList.toggle("red")
# See if the layer has class .red
print layerA.classList.contains("red")
# Output: true