Archive for April, 2009
code hinting in a prefixless world
Now that the Fx component prefix is on its way out (here’s a more nuanced explanation), good code hinting gets a little trickier. Most of the common Spark components will have same-named Halo cousins that skin differently (for instance, spark.components.Button and mx.controls.Button), and simply hinting both of them is bound to cause confusion.
Here are some aspects we’ve considered while discussing this:
- New Flex developers (and really, even a lot of seasoned vets) won’t know what “Halo” and “Spark” mean. So while it’s helpful to include Spark/Halo in the hint (via the package name, one of the things that got improved in the big rename), that only helps if you understand the implication of those terms or package names.
- For most new SDK4 projects, the expectation is that Spark components will 100% supercede their Halo cousins. So hopefully, for a fresh project you won’t need mx:Button.
- The ActionScript editor should probably hint every possible class, but select Spark classes as the default when there are overlaps; for MXML, a “preferred components only” hint list is preferable.
- Hey, what should the Components panel show?
I think we have pretty good ideas that address the above list and still provide preferences for devs whose needs are different.
I’m curious though — for those of you who have been using Gumbo beta SDKs, do your expectations match the above? For new projects, how much do you expect to use Halo components that have Spark equivalents? Are you planning to port your legacy apps to include Spark namespaces and components, and if so what classes/components would you want to show up in code hints?
2 comments