View Poll Results: Do you like the new Field class names?
- 13. You may not vote on this poll
12 Nov 2010 7:14 AM #1
Do you like the new Field class names?
I'm all open for cleaning up the API.
Though, I'm not happy with the recent API changes regarding the form field classes in Sencha Touch 1.0 RC1.
Ext.form.DatePickerField renamed to Ext.form.DatePicker Ext.form.EmailField renamed to Ext.form.Email Ext.form.HiddenField renamed to Ext.form.Hidden Ext.form.NumberField renamed to Ext.form.Number Ext.form.PasswordField renamed to Ext.form.Password Ext.form.SearchField renamed to Ext.form.Search Ext.form.SpinnerField renamed to Ext.form.Spinner Ext.form.TextField renamed to Ext.form.Text Ext.form.UrlField renamed to Ext.form.Url
You may *guess* that it's a field because of the form namespace. But why guessing when it can be explicit.
Well, that are just my 2 cents.
Woud like to know what others think, therefore I added a nice poll.
12 Nov 2010 7:35 AM #2
I don't mean to sound pessimistic, but, I doubt they will change. I say this because there is a significant cost savings in changing these names.
Btw, I think you can expect these changes in Ext JS 4.
12 Nov 2010 7:40 AM #3
The issue I have with it is that it breaks compatibility with the currently released ExtJS.
We are writing a mobile version of our webapp and share quite a bit of code between the two to ensure consistency in business logic, as well as some UI aspects that are similar between the two platforms. Anything that differs between desktop and mobile is put into subclasses or other leaf-code files. Naturally, this approach is not without problems due to the platform differences, but the more consistent the two are, the less we have to refactor to just get the app going.
However, we are stuck on an older beta of Sencha Touch (0.95) because of changes like this one as well as changes to Ext.util.MixedCollection that were made in 0.99 that break compatibility with ExtJS. This would not be a huge deal, except that the version of ExtJS we are on is fairly recent (3.2.2), the latest ExtJS (3.3) does not include these changes (nor should it!), and 4.0 -- which may or may not contain these changes -- is not even in beta yet (AFAIK).
Side note: We aren't on 0.98 because time constraints did not permit us to upgrade (0.96-0.98 saw significant changes in Sass and code). The difference is that the changes are specific to Touch, which is in beta, and we accept that beta APIs will change. The Field and MixedCollection changes are not like that, however.
Last edited by cdonnellytx; 12 Nov 2010 at 7:41 AM. Reason: to clarify "breaks compatibility with *current* releases"
12 Nov 2010 7:44 AM #4
Well, first I want to see what other people think and if someone has a good explanation for those changes.
They said they will include those changes in Ext JS 4. So if they change those names, it would have to be before Ext JS 4.
But like I said, I first want to create a space to talk about those changes.
What significant cost savings do you mean, Jay? For me the changes have a cost by loosing the class names clarity.
12 Nov 2010 7:47 AM #5
cdonnellytx, Ext JS 4 will share all those new APIs with Sencha Touch. In the code you can see that they separate all classes that can be shared into a platform folder.
12 Nov 2010 7:48 AM #6
That said, there will be a "Legacy" layer that Ext JS 4 will come with to help w/ compatibility.
Regarding "breaking changes" with Sencha Touch, you are building software with alpha/beta software. it's bound to change! You take that risk.
I stopped developing apps in ST .93 because of breaking changes with .94 to .93, along with stability issues.
12 Nov 2010 7:50 AM #7Cost savings in terms of footprint/space.
12 Nov 2010 8:03 AM #8
And don't talk about gzip, because a lot of developers don't have a clue what gzip is, let alone how it plays a role in server side content delivery.
The Sencha team has a lot of *really* smart developers on the team now, instead of just a few. They are making hard choices to make the framework better. This is one of them.
12 Nov 2010 8:11 AM #9
Still don't buy the footprint argument, since my opinion is that we loose clarity. Tomorrow we will rename Ext.TabPanel to Ext.Tab or Ext.T to save another few bytes?
You didn't need to mention the smartness of the developers, I do highly respect them.
Still, a forum is about sharing opinions.
12 Nov 2010 8:24 AM #10