-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
paper-elements rfc specifications #23
Comments
+1 |
Agreed, it's not really consistent. I think in newer elements we've tried to stick more to the "class" name vs the "attribute" name approach (even though in /cc @tjsavage for ideas |
Our line has typically been this is an element-by-element decision. I agree, we should have generally consistently-applied rules around when we prefer classes vs. attributes - based on many of our examples I might say a rough rule is "use attributes to denote children that are required by the parent" and "use classes to denote a kind of child that is not required by the parent element." Does this seem off-base? That said, we shouldn't have glaring inconsistencies. I think in many cases we don't necessarily have to make a breaking change - we could update elements such that styles and selectors apply for both the class and the attribute, and update the documentation to only reflect the "right" way of denoting the child, and also document that the old way is deprecated. We may also add in deprecation warnings to polylint. This will be a tradeoff between adding complexity and duplication to elements vs. a smooth API surface. I think broadly we should try to arc toward greater consistency while we're on ^1.0.0, but make sure if we jump to 2.0.0 we take a hard look at the element's use of class vs. attributes. I don't think we should break elements strictly to change attribute vs. class usage, but definitely deprecate where appropriate and possible and take advantage of any other breaking changes to put in the right usage. |
Just focus on 2.0, it's too much energie and code required to implement a deprecate warning solution for 1.0. Upgrading from 1.0 to 2.0 wil be a breeze compared to 0.5 -> 1.0 :D Start by comparing elements and map how much inconsistency we are talking about including styling and naming conventions. I want to see @arthurevans list he was working on a year ago :P Make that list public like a polymer element 2.0 rfc. If I can see that list I know we are on the right track for 2.0 and everybody can make a 2.0 branch based on that element 2.0 rfc. PS let me know when the rfc is online so I can spam my attribute, style en class issues there instead. |
^ Totally fair request. I think it's a bit soon for a complete 2.0 proposal, but I think it's a good idea to start aggregating proposed 2.0 changes in a public place for comment. I want to avoid as much as possible the risk of such as step coming across as "new thing coming soon, so don't use today's thing," as it would certainly be evolutionary from the 1.0 versions. We'll message loud and clear though when such an rfc is up. |
Give it a other name then, polymer rfc without a version. I want to avoid as much as possible the risk of new inconsistent elements being born :) without a proper convention molecules decay quickly and release bad radiation to new developers who are not shielded against polymer radiation :) Remember does things still have to be assembled together and every attribute resembles a different wrench :) |
/sub |
Don't let Polymer 2.0 fly under the radar again, if we are going to break things we should really break things. Where is the element design spec we where promised that standardised attribute naming conventions etc? Polymer 2.0 should comme with strict element build naming conventions as promised before even thinking about releasing anything that has a 2.0 in its name. Now is the time to clean everything up and break every single element if necessary! Please create a repository that just contains the naming conventions specifications to start with. Thank you |
First, in Polymer 2.0 this won't be an issue anymore, so this naming convention document is moot: in the v1 spec, distribution is done via a named <paper-drawer-panel>
<div slot="drawer"> Drawer panel... </div>
<div slot="main"> Main panel... </div>
</paper-drawer-panel> As for the other breaking changes in 2.0, we're trying to make the 1.0 -> 2.0 transition as smooth as possible (blog post), so that it doesn't take another year for teams to upgrade, like what happened for 0.5. This means that the area for breaking changes is much smaller. |
The 'easy' transition is mainly done because a handfull of people is going to be responsible to upgrade thousand of internal google products that uses polymer right now :P All I ask is a specification. Even emoji have rfc specifications. If paper-elements and iron-elements don't want to follow the spec fine, create a new branch called rfc-elements that follow the spec, thanks |
As I mentioned in my previous message, the initial concern about class vs name consistency comes from how distribution was done in the v0 spec, with |
And the list goes on and on for keywords that are common in every element and currently is the wild wild west with no specification what so ever for third party developers. |
Just want to add another example of inconsistency because of lack of specifications https://elements.polymer-project.org/elements/paper-tabs The sad part is not that there are inconsistencies but because of corporations not allowing us to fix it. Open Source means breaking and fixing things... allot! |
https://elements.polymer-project.org/elements/paper-header-panel
https://elements.polymer-project.org/elements/paper-drawer-panel
Who was counting container ships during the
attribute
andclass
consistency meeting?Polymer/polymer#1011 damit!
The text was updated successfully, but these errors were encountered: