Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#18472 closed defect (wontfix)

rename class property to className

Reported by: dojonovice@… Owned by:
Priority: undecided Milestone: tbd
Component: Dijit Version: 1.10.4
Keywords: Cc:
Blocked By: Blocking:

Description

Why dijit Button using class property instead of className?

This doesn't work.

new Button({ label : button.label, className : button.type, onClick : button.action})

This works fine.

new Button({ label : button.label, class : button.type, onClick : button.action})

Is it right?

Change History (1)

comment:1 Changed 5 years ago by bill

Component: Dijit - FormDijit
Resolution: wontfix
Status: newclosed
Summary: dijit/form/Button and classNamerename class property to className

Yes, probably we should have named it className, but it's named class. Perhaps to support declarative widgets more easily. Anyway it's not something that we can change now, because it would break the existing API.

Last edited 5 years ago by bill (previous) (diff)
Note: See TracTickets for help on using tickets.