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

Removed dashes from some non-core detects' names. #719

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
3 participants
@ghost

ghost commented Oct 2, 2012

These dashes are preventing these detects from being queried in JS like every other test. For example, at the moment one can use

if (!Modernizr.fontface) {
    /* Do something. */
}

to test for @font-face support, but one must use

if (!Modernizr["display-table"]) {
    /* Do something. */
}

to achieve the same for display: table. This introduces, of course, a backwards-incompatible change, but helps in keeping project-wide code style and library-wide naming consistency.

Build Status

bmcustodio
Removed dashes from some non-core detects' names.
These dashes were preventing these detects to be queried in JS like every other
test (e.g., 'Modernizr["display-table"]' as opposed to 'Modernizr.fontface'.).
This introduces, of course, a backwards-incompatible change, but helps in
keeping project-wide code-style and library-wide naming consistency.
@SlexAxton

This comment has been minimized.

Member

SlexAxton commented Oct 2, 2012

I think this is a good move, but maybe not til 3.0 with the AMD names and stuff.

@KuraFire

This comment has been minimized.

Member

KuraFire commented Oct 2, 2012

Agreed; when we hit 3.0 we'll likely be making various backwards-incompatible changes with compatibility aliases as it is, so these changes are a good candidate for merging at that time.

@ghost

This comment has been minimized.

ghost commented Oct 2, 2012

Nice guys. Glad this will be of some help. :-)

@paulirish

This comment has been minimized.

Member

paulirish commented Jan 7, 2013

@bmcustodio can you repeat this PR for the v3 branch?

@paulirish

This comment has been minimized.

Member

paulirish commented Jan 7, 2013

Also can you add a test in qunit which fails on dashed names?

@ghost

This comment has been minimized.

ghost commented Jan 8, 2013

@paulirish: Sure I can. Please allow me a few hours, though, so that I can fix a few problems with my workstation.

@ghost ghost closed this Jan 8, 2013

@ghost

This comment has been minimized.

ghost commented Jan 8, 2013

@paulirish: Done in #782. :-)

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment