Skip to content
This repository was archived by the owner on May 14, 2021. It is now read-only.

use unique name for each wrapped selector #28

Merged
merged 1 commit into from
May 23, 2017
Merged

use unique name for each wrapped selector #28

merged 1 commit into from
May 23, 2017

Conversation

sergioramos
Copy link
Contributor

No description provided.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.006%) to 99.213% when pulling caf4568 on ramitos:rnd-selector into 9842e3e on styled-components:master.

@mxstbr
Copy link
Member

mxstbr commented May 22, 2017

Is this necessary/does it fix anything? I haven't run into any trouble just using .selector...

@sergioramos
Copy link
Contributor Author

yes, it conflicts with https://github.com/primer/stylelint-config-primer/blob/master/index.js#L263

Copy link
Member

@mxstbr mxstbr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I see, that's nice! Maybe rather than using randomstring (which still has the potential for a collision, however small that chance is) we could use an incrementing selector? That way we never have collisons! Something like .selector-1, .selector-2 etc.

@sergioramos
Copy link
Contributor Author

@mxstbr incrementing selector is a simple and great idea, will do that!

@coveralls
Copy link

Coverage Status

Coverage increased (+0.006%) to 99.213% when pulling 0f9e146 on ramitos:rnd-selector into 3ad3aa1 on styled-components:master.

@sergioramos
Copy link
Contributor Author

@mxstbr updated

@sergioramos sergioramos changed the title use random name for each wrapped selector use unique name for each wrapped selector May 23, 2017
@mxstbr
Copy link
Member

mxstbr commented May 23, 2017

This is great, thanks so much!

@mxstbr mxstbr merged commit 68b4c4f into styled-components:master May 23, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants