[Function <name>] (glob) {
$.src(glob)
.pipe([plugin 1])
.pipe([plugin 2])
.
.
.
.pipe([plugin n])
.pipe( $.dest(<destination-name>)
}
Note
pipe is a method that streams all the files matching the glob input , to our plugins( minifyhtml in this case) .
It is simple ...
So, Before writing out optimiser functions , we need to install a couple of caching plugins.
bash $ npm install --save-dev gulp-cached
bash $ npm install --save-dev gulp-remember
You might wonder why two caches eh!. gulp-cached , passes only modified or new content down the pipeline to other ...
The anatomy of a task definition is like so:
$.task(<taskname> , [dependencies] , <body>);
dependencies , is an array of tasks that HAVE to finish before the current task you are defining , runs. More like forcing a synchronous execution instead of the default Asynchronous functionalit...
So, we now have
A function defined Above to optimise Styles
A function defined Above to optimise scripts
A function defined Above to optimise HTML
A function to generate multiple images per image Above
All we need to do now, is to invoke them when needed.
Let us write our tasks according t...
NOTE
This page illustrates use of gulp plugins like browser-sync ,
gulp-watch and run-sequence , and continues discussing
gulp-workflow-automation from where we left off at
Gulpjs-workflow-automation-1 of 2. In case you landed here , consider
going through that post first.
Default Task
...
So now, let us finish the gulpfile code , by defining a Default task.
the default task is the one that runs, when you just say
gulp
on a command prompt under the root of your project.
$.task('default', ['generateResponsiveImages'], function() {
$.start('watchdog');
console.log('Starting In...
This example scans for available access points and ad hoc networks. btnScan activates a scan initiated by the WifiManager.startScan() method. After the scan, WifiManager calls the SCAN_RESULTS_AVAILABLE_ACTION intent and the WifiScanReceiver class processes the scan result. The results are displaye...
Disable Private Browsing
Open your device’s Safari settings and ensure that Private Browsing is turned off. Remote debugging will not work if Private Browsing is enabled.
Enable Web Inspector
Tap the Advanced tab on your device’s Safari settings and ensure that Web Inspector is turned on....
Parallel GC is Stop-The-World (STW) collector which stop all the application threads when running the garbage collector.
When Parallel GC was introduced it was only enabled the parallel GC in young generation collector and OldGeneration Collector was single thread stop-the-world collector, but late...
Installing mvvmcross with nugget:
Search for mvvmcross in the "Manage Nugget Packages" window.
Installing mvvmcross with Package Manger Console:
PM> Install-Package MvvmCross
Make sure to install it on both your PCL (Portable Class Library) and you application project.
As the...
The returned value is intended to be suitable for use in a URL, not as a human-readable title. Use sanitize_text_field instead.
$new_url = sanitize_title($title);
$incfile = sanitize_file_name($_REQUEST["file"]);
include($incfile . ".php");
Without sanitizing the file name an attacker could simple pass http://attacker_site/malicous_page as input and execute whatever code in your server.