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
var script = document.createElement('script'); | |
script.type = 'text/javascript'; | |
script.src = 'https://code.jquery.com/jquery-3.2.1.min.js'; | |
document.head.appendChild(script); |
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
$(window).load(function() { | |
//----ADJUST FONTSIZE IN MOBILE | |
if (isMobile()) { | |
$('h1, h2, h3, h4').each(function() { | |
var $this = $(this); | |
var text = $this.text(); | |
$this.empty().append('<span style="color:inherit">' + text + '</span>'); | |
var width = $this.width(); |
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
$owlHistory.trigger('to.owl.carousel', [0,100]); |
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
leafletMap.dragging.disable(); | |
leafletMap.touchZoom.disable(); | |
leafletMap.doubleClickZoom.disable(); | |
leafletMap.scrollWheelZoom.disable(); | |
leafletMap.boxZoom.disable(); | |
leafletMap.keyboard.disable(); | |
if (leafletMap.tap) leafletMap.tap.disable(); | |
document.getElementById('mapid').style.cursor = 'default'; |
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
function shuffle(array) { | |
var currentIndex = array.length, | |
temporaryValue, randomIndex; | |
// While there remain elements to shuffle... | |
while (0 !== currentIndex) { | |
// Pick a remaining element... | |
randomIndex = Math.floor(Math.random() * currentIndex); | |
currentIndex -= 1; |
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
function getRnd(max, min) { | |
return Math.random() * (max - min) + min; | |
} |
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
<a href="#" class="close-btn">×</a> |
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
cd existing_folder | |
git init | |
git remote add origin [email protected]:radiodraws/react-gist-app.git | |
git add . | |
git commit -m "Initial commit" | |
git push -u origin master |
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
console.log('<br>Computed style width as pixels: '); | |
console.log(node.style('width')); | |
console.log('<br>Computed style width as a number: '); | |
console.log(parseFloat(node.style('width'))); | |
console.log('<br>As a percent: '); | |
console.log(node.node().style.width); | |
console.log('<br>Actual width as number: '); | |
console.log(node.node().offsetWidth); |