Created
August 17, 2018 16:29
-
-
Save DrewAPicture/b4faa5e51956bcec13604f5bae32e96f to your computer and use it in GitHub Desktop.
SellBird registration URL live-preview JS.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$( '#store-name' ).on( 'keyup', function( event ) { | |
var toConvert = $( this ).val(), | |
converted = toConvert.replace( /\s+/g, '-' ).toLowerCase(), | |
description = $( this ).next( '.form-text' ); | |
description.text( 'e.g. ' + converted + '.sellbird.com' ); | |
} ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment