JS error http://cl.ly/W1rX
JS Detail http://cl.ly/W1uc
<img data-interchange="[//bevel-assets.s3.amazonaws.com/checkout/order-products.png,(default)], [//bevel-assets.s3.amazonaws.com/checkout/[email protected], (retina)]" src="" width="100%"> |
$> cat Gemfile.lock|grep foundation | |
remote: git://github.com/alexkrus/foundation-icons-sass-rails | |
foundation-icons-sass-rails (3.0.0) | |
foundation-rails (5.2.3.0) | |
foundation-icons-sass-rails! | |
foundation-rails |
JS error http://cl.ly/W1rX
JS Detail http://cl.ly/W1uc
x = '//bevel-assets.s3.amazonaws.com/proof/before-after-1.png,(default)'
y = '//bevel-assets.s3.amazonaws.com/pro,of/before,-after-1.png,(default)'
/**
Pattern: /(^.+\.[aA-zZ]{1,4}\,\((.+)\)/
should match path + extensions (gif,jpg,jpeg,png,svg,etc.)
*/
//instead of regex split using group matching
x.match(/(^.+\.[aA-zZ]{1,4}\,\((.+)\)/)
/**
[ '//bevel-assets.s3.amazonaws.com/proof/before-after-1.png,(default)',
'//bevel-assets.s3.amazonaws.com/proof/before-after-1.png',
'default',
index: 0,
input: '//bevel-assets.s3.amazonaws.com/proof/before-after-1.png,(default)' ]
*/
y.match(/(^.+\.[aA-zZ]{1,4}\,\((.+)\)/)
/**
[ '//bevel-assets.s3.amazonaws.com/pro,of/before,-after-1.png,(default)',
'//bevel-assets.s3.amazonaws.com/pro,of/before,-after-1.png',
'default',
index: 0,
input: '//bevel-assets.s3.amazonaws.com/pro,of/before,-after-1.png,(default)' ]
*/
Hi, @tjhandley
Is this specific towards handling situations where you don't have a protocol, or something else?
Do you recommend this solution to be included part of
parse_data_attr
or somewhere else?