As easy as 1, 2, 3!
Updated:
- Aug, 08, 2022 update
config
docs for npm 8+ - Jul 27, 2021 add private scopes
- Jul 22, 2021 add dist tags
- Jun 20, 2021 update for
--access=public
- Sep 07, 2020 update docs for
npm version
#!/usr/bin/env sh | |
# Download lists, unpack and filter, write to stdout | |
curl -s https://www.iblocklist.com/lists.php \ | |
| sed -n "s/.*value='\(http:.*=bt_.*\)'.*/\1/p" \ | |
| xargs wget -O - \ | |
| gunzip \ | |
| egrep -v '^#' |
/** | |
* Prepare the App Folder | |
*/ | |
(function(){ | |
window.appRootDirName = ".myapp"; | |
document.addEventListener("deviceready", onDeviceReady, false); | |
function onDeviceReady() { | |
console.log("device is ready"); | |
window.requestFileSystem = window.requestFileSystem || window.webkitRequestFileSystem; |
var iOS = require('iOS'); | |
iOS.createNotification({ | |
header: 'node-iOS Rocks!', | |
message: 'How much does running \'node\' on your iPhone rock?', | |
defaultButton: 'A lot!', | |
alternateButton: 'It rocks my socks' | |
}, function(err, res){ | |
if (err) throw err; | |
console.log(res); |
// 1: how could you rewrite the following to make it shorter? | |
if (foo) { | |
bar.doSomething(el); | |
} else { | |
bar.doSomethingElse(el); | |
} | |
// 1: how could you rewrite the following to make it shorter? | |
foo ? bar.doSomething(el) : bar.doSomethingElse(el); | |
// 2: what is the faulty logic in the following code? | |
var foo = 'hello'; | |
(function() { |