Intentionally break your map canvas using the resize container
button, then fix it again using the fix map
button. This little demo is designed to show off how Mapbox GL JS's map.resize()
method can fix a squished or stretched map canvas by telling the map to 1) check the size of its container, then 2) trigger a re-render. This method is useful for applications where the map's container might be resized interactively through a sliding, expanding, contracting, or interactively hidden HTML element.
This file contains 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(global){ | |
"use strict"; | |
function constEnumPropValueDesc(v){ | |
return { | |
value: v, | |
enumerable: true, | |
configurable: false, | |
writable: false | |
}; |
This file contains 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(global){ | |
"use strict"; | |
function constEnumPropValueDesc(v){ | |
return { | |
value: v, | |
enumerable: true, | |
configurable: false, | |
writable: false | |
}; |
This file contains 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
processor : 0 | |
vendor_id : GenuineIntel | |
cpu family : 6 | |
model : 28 | |
model name : Intel(R) Atom(TM) CPU Z520 @ 1.33GHz | |
stepping : 2 | |
microcode : 0x217 | |
cpu MHz : 800.000 | |
cache size : 512 KB | |
physical id : 0 |
This file contains 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
for f in /usr/share/figlet/* | |
do | |
fs=$(basename $f) | |
fname=${fs%%.tlf} | |
toilet -f $fname $fname | |
done |
Note: This was written in 2015, it may be out of date now.
There are a lot of commands here which I use
sudo
if you don't know what you're doing withsudo
, especially where Irm
you can severely screw up your system.
There are many reasons which you would want to remove a piece of software such as McAfee, such as not wanting it to hammer your CPU during work hours which seems like primetime for a virus scan.
I intend this to be a living document, I have included suggestions from peoples' replies.
This file contains 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
# | |
# mkcd command | |
# This is an improvised version of the mkcd command at http://superuser.com/questions/152794/is-there-a-shortcut-to-mkdir-foo-and-immediately-cd-into-it | |
# This function has to be added to the ~/.bashrc file | |
# After that you can run command like: mkdir abc, mkdir -p one/two/three | |
# | |
function mkcd { | |
last=$(eval "echo \$$#") | |
if [ ! -n "$last" ]; then | |
echo "Enter a directory name" |
OlderNewer