How to remove multiple files from a GIT repo that have already been deleted from disk?
Using the command gitrm $(gitls-files –deleted)
There is a fine yet conspicuous difference between a successful web business model and a successful and sustainable web business model. In case of a web business that aims to sustain and succeed, which is what every business owners would love to achieve, the same metrics are to be incorporated but, with the addition of foresight. This foresight or predictive analysis is what that is necessary for a business to sustain, develop and prosper in the upcoming future.
Predictive Analysis is the technique that involves mining of data and analysis of statistics to give a prediction of future user behaviour, trends, events etc. This technique clears the mirages ahead of web businesses and gives them a clear view of what lies ahead so that mistakes are avoided and adjustments in tune with the upcoming events are made in time.
Companies that benefited with Predictive Analysis Techniques:
A lucid example of predictive analysis can be found in Facebook’s news feed. In its nascent stage, Facebook’s news feed feature used to display updates of all of a user’s friends in a chronological order. However, the news feed now prominently features updates from those friends/family with whom the user interacts most. This is due to the wave of the predictive analysis wand that resulted in the creation of an algorithm that predicts which stories a user might be interested in, based on most frequent interactions and profile details.
An aspect of Amazon where the implementation of predictive analysis is ubiquitous is the recommendations that one sees on the website. These recommendations are smartly displayed to users compelling them to view more and consequently end up purchasing more. The cause behind this smart display and effective business tactic is a diligent analysis of user behavioural patterns and terabytes of scattered data.
Predictive Analysis Techniques:
Predictive Analysis encompasses a number of techniques that are employed to know about the likelihood of events, assessment of user behaviour and probable consequences for a range of decisions.
These techniques are broadly classified under
Making the most of Predictive Analytics to improve conversion rates:
Predictive analytics factors in all possible variables that help the marketer devise the right strategy to generate the desired engagement with customers – from providing timely and accurate sales forecasting insights, to equipping them with opportunities to improve diagnosis.
These insights can range from
As in the case of any other technique, system or ideology, Predictive Analysis is not flawless and perfectly accurate either. It must always be remembered that though predictions are made and probabilities seen on the basis of scientific reasoning and logical analysis, they still remain an “Analysis”, a “Probability”. Their limitations not withstanding, this technique is no longer the prerogative of renowned industry stalwarts but is being implemented by small, large companies and unicorn start-ups alike.
Agile methodology is a collection of software development strategies in which requirements are obtained through collaboration between self organizing teams. It is a term that was derived from the Agile manifesto, which was written in 2001 by a technical group that included developers of Scrum, Extreme Programming and Dynamic Systems Development Method. The Agile process promotes and requires that functionalities with higher business value are done first.
Popularity of Agile methodology:
According to a study conducted by Version One, Technology Company known for development of Agile lifecycle management software, 94 percent of business organizations in the world are practicing Agile. It is quickly becoming the de facto standard of software development and Agile will become the best practice of software development in the next ten years. Acceleration of product delivery, accommodation of change and driving of productivity are the main reasons for the high popularity of Agile methodology. Connoisseurs of web development believe that Agile methodology is all about delivering value to the business on a repeatable, reliable and rapid fashion.
Transitioning from waterfall to Agile:
The advantages of Agile over Waterfall are conspicuous and businesses, whose very success depends on making the most advantageous decisions, are flocking to the Agile methodology. In a plethora of companies that have been baptized as Agile in recent times, Toyota is a brand that deserves a detailed mention.
The name Toyota has become synonymous with fast, efficient, luxurious and dependable automobiles. What most of us don’t know is that Toyota does not just make cars, it also develops its own software. The folks at Toyota understand the importance of automatic electronic control system which is why the Project General Manager from the Automotive Software Engineering Department, Mr. S. Ishii referring to the importance of developing software for their cars, said that “Toyota needs to become an IT company”. Mr. Ishii said that they would probably be shifting their approach from Waterfall to Agile.
He stressed on the importance of detecting bugs early in the development cycle to prevent expensive rectifications. A defect detected in the prototyping stage is 50 times less expensive than if it is discovered in the production phase. The defect will be dearer by 1000 to 10000 times if it is discovered after the production phase. The fact that Toyota is incurring a cost of 2 billion dollars due to recalls and lost sales that were the result of a software glitch in the braking system of their Prius model has made them think of how important prompt detection of issues is. This made them transform from waterfall to Agile.
How Agile & Scrum go mainstream?
As Agile does not provide concrete steps, organizations seek more specific methods within the Agile environment including crystal clear, extreme programming, feature driven development, dynamic systems development method and Scrum. Scrum gives special importance to decision making from real time scenarios rather than speculation. It can be defined as a simple set of roles, responsibilities and meeting that never ever changes.
12 Principles of Agile Development Manifesto:
Scrum is an iterative development process and projects progress via a series of iterations called sprints. It does not include any traditional software engineering roles such as programmer, designer, tester and architect. The scrum team forms a common ownership of the work to be performed rather than just focusing on particular task.
While scrum is the most popular example that encapsulates agile philosophy, there are a number of Agile techniques available including pair programming, test driven development and continuous integration.
Overall, Agile manifesto deals with four core values of individuals and their interactions, delivering working software, customer collaboration and high performing teams which is the reason it’s continuing to be a Driving Force behind Software Development.
Yes, the old debate of whether basing a customer’s online experience should be limited to a single device is still going on! The fact that a professional or business would want to over-simplify their website’s user-experience seems like the perfect recipe for failure.
Although a lot of web developers believe and advocate the use of responsive designs, there is almost unanimous agreement that having a responsive website doesn’t mean that you’re set for life. The fact that a website is responsive only means that it is viewable on a multitude of devices. It doesn’t necessarily guarantee that the user will have an enjoyable experience.
Now you might think that your customers might not expect much from your mobile website because they understand that you can only do so much with a limited screen size. The truth, however, is the exact opposite as the next-gen users want the best of everything, all the time! Whether they’re booking movie tickets on their desktops or buying a pair of shoes through their smartphones, people want to have a quick and seamless transaction.
Benefits of Mobile-first:
In Mobile First approach, the idea of designing the Smartphone experience comes first and then developing the design for tablets, desktops and possibly beyond. Considering a mobile website first enables developers to meet mobile users’ requirements on a very basic level. This is of course due to the major constraints of both performances as well as size of a mobile platform. Not only are mobile users confined to a device with a physically smaller screen, but they typically run on lower connection speeds, restrictive data plans or even no data plan at all! This forces developers to be more concise and focused on the kind of content that they wish to deliver to the client.
It makes them think twice before simply filling up their websites with unnecessary fluff. Here are the few advantages of mobile first:
If you’re still not convinced that a mobile first approach would cause more harm than good for your website and your overall business, here are a few more pointers that should help you seal the deal:
Problems with Mobile First:
The mobile first approach may not be the best choice if there is a limited budget or a pre-existing site design. Restructuring a website that is already designed and going back to the drawing board to begin with an entirely new process can be costly and it takes a long time. Here are the few drawbacks of mobile first:
However, these drawbacks should not be the primary focus. Rather, the different needs of the target audience and strategic goals of the website should be at the forefront of all considerations. In fact, web designers and developers alike have been oversimplifying the issue of mobile first since the early 2000s, which has led many to believe that responsive web design is the answer to all of their development woes. Also, it’s possible that the best practices of mobile design will subsume desktop design, bringing simpler and more efficient interfaces to users everywhere.
The Final Verdict:
Typically, a responsive design is structured around the concept of numerous media queries that target certain devices that have specific screen size restraints. And with this information in hand, you can easily create codes for your initial CSS design and then eventually use these media queries to draft additional size support.
And if you think that you can ignore all of this by either maintaining two separate websites, you are gravely mistaken. If you build a separate mobile website by totally avoiding the use of a responsive design, you will end up with two fully-functional websites. This subsequently gives you two entire codebases to design and maintain, doubling your work. Ultimately, it’s best to get over the platform-first approach and embrace the mobile first approach, for your own convenience and the convenience of all your users.
Based on the concept of responsive architectural design, the ground breaking approach of Responsive Web Design was created. With the perpetually evolving nature of technology and the copious releases of newer and better devices, it was necessary that this approach be formulated.
Having appreciated the efforts of the pioneers behind the RWD approach and the technology itself, let us now shift our attention to the requirements of the contemporary market. The cut-throat competition, the increasingly prevalent emergence of complete web based businesses and the abundant availability of smartphones has increased the importance of RWD for clients.There are many testing tools in the market that check the transitions and assess compatibility but out of the plethora of options available, three stand out.
Adobe Edge Inspect CC
Top of the list is Adobe Edge Inspect, the erstwhile “Adobe Shadow” which is one of the many tools released under the ambit of Adobe Edge, the suite. This tool was developed to preview web designs on popular mobile formats. The primary aim however, was to prevent the design’s associated files from being published onto a server. This tool enables each mobile device paired with the computer to display the same site in its own specific render and mode of presentation be it either IOS or Android. Instead of the routine and standard practise of previewing a site that has been optimized for mobile viewing on a desktop system, the file is sent to the paired devices using this tool where the transition happens and the transformed view is displayed.
This tool also enables live editing of code with the changes being displayed on the paired devices as they are made. The connection host computer can also remotely collect all screenshots from the paired devices using this tool. Wireless pairing of multiple android & IOS devices is possible with this tool. In addition to the above, Adobe Edge Inspect also allows; changes to be made to HTML mark ups, tweaks in CSS rules, JS bin integration, clear caches in devices and refresh pages. It also supports HTTP & SSL/HTTPS authentication support.
Visual feedback + bug reporting on responsive web sites
Next comes the bug tracker tool Usersnap. This tool can be added as a widget to any web browser and used as a bug tracking system thereby enabling developers to improve Q&A process for projects. The tool’s “Feedback Widget” provides a unique method of reporting where the bug information is displayed on the page itself. It also allows developers and designers to seek clarification through feedback forms if required. These forms, that come in a number of attractive themes, only ask for comments, that’s all, no exhaustive information sought, no hassles for the users.
It enables sending of bug reports as screenshots without the aid of any plug in. Numerous options of demarcating the bugs such as, highlighting, using a pen, adding a note, blacking out the area, using arrows, pixel rulers and adding comments have been incorporated simplifying the entire process. The website loading time and performance remains unaffected as the tool is loaded asynchronously and delivered through a strong CDN. Also, Browser specific issues can be viewed immediately as a view of the user’s browser is sent as a screenshot.
The third on the list is Mobitest, a free tool that enables testers to enter a URL, choose the device they want to run the test for, select the number of tests that are to be run and hit enter. As simple as that. The page is then loaded on a mobile device and detailed information such as the time taken for loading, waterfall charts and the page load video recording are provided. The advantage offered by Mobitest is that tests need only be specified once. Test suites for each platform will be generated automatically. The tool allows developers to specify a single set of tests for applications. These tests can then be used with each platform upon which the application is being developed.
Apart from these tools, there is another tool we thought of sharing with you as a bonus is Google DevTools, which is a very powerful tool and the device mode makes it an even more indispensable part of the modern web designer’s toolkit. Developers can take advantage of Chrome’s new “Screencast” technology by simply connecting their mobile device via USB and enable “USB Debugging” within the device settings. Google Chrome will take care of the rest by auto discovering your handset and integrating it within the developer tools options. With this, one can connect debug the webpage opened on mobile browsers. This helps developers in rectifying the issues like rendering, debugging remotely and more using desktop browser devtools.
Accessing the Scope through DOM
Few optimization tweaks are recommended for production and one of them is disabling debug information. DebugInfoEnabled is a setting which defaults to true and it allows for scope access through DOM nodes. If web developers want to try this, they should select a DOM element and access its scope with: Angular. Element (document.body).scope ( )
Not Using Named Views with UI Router
De-facto routing solution for AngularJS has been the UI-Router and ngRoute is basic for more sophisticated routing. There is a new NgRouter on its way and web development experts term it as basic for more sophisticated routing. UI-Router is prominent because it has awesome basic nesting, route abstraction and optional parameters. Solution to this mistake can be obtained from HTML code and it is necessary to separate them into files and states
Declaring Everything in the Angular World Using Anonymous Functions
This mistake is of very light importance and it is a question of style than avoiding Angular JS error message. If functions are assigned to a variable, web developers can manipulate and mutate functions. The code will be cleaner and it can be very easily split into files. By avoiding this mistake, web development experts get more expressive power through reusable code and splitting all code in self contained blocks is just bette.
JQuerying It-Detached DOM Tree
It is not recommended to use JQuery with Angular JS and it should be avoided at all costs.
Overusing Isolated Scope
There are two reasons for this issue and the first one is that we can’t apply two isolated scope directives to an element and we will have to encounter issues with nesting/inheritance/event processing.
Not Cleaning up Watchers, Intervals, Timeouts and Variables
Not cleaning up any watchers that are not bound to the current scope, intervals, timeouts, variables referencing DOM and JQuery plug-in is a mistake made by even experienced JS Developers. If the above mentioned tasks are not completed manually, we will have to encounter unexpected behavior and memory leaks.
Misunderstanding the Digest
Angular JS updates DOM as a result of callback functions to watchers and watchers are set for many other directives such as ng-if and ng-repeat.
Managing Numerous Watchers
The cycle can cause several performance problems if the number of watchers exceeds about 2000. This is due to the dirty checking that is carried out in a digest cycle.
The aforementioned Immediately Invoked Function Expression (IIFE) prints the number of watchers presently on the page. To view the total number of current watchers on a page, just paste the IIFE in the console.
By employing this technique, ascertaining of the existence of duplication or whether unchanging data has a watch is made possible. Use Bindonce to template unchanged data using Angular. Bindonce is a simple directive that allows usage of templates within Angular. However, this does not prevent the count from increasing.
Leaving Batarang On The Shelf
A Google Chrome extension for debugging and developing AngularJS apps, Batarang is a great tool for developers. Batarang enables model browsing to learn the models that are bound to scopes as determined by Angular. This can be useful in isolation of scopes in order to be able to see where the locations are bound. It can also be helpful during working with directives. Whilst entering an untested codebase, Batarang helps determine which services should get the most attention. It also offers a dependency graph.
Offering performance analysis, Batarang enables detection of functions that take the most time in the digest cycle. In addition to the aforementioned benefits, non-utilization of Batarang also prevents developers from viewing the full watch tree, which can come in very handy when dealing with numerous watchers.
Utilization of jQuery
It’s standardized cross platform development and becoming almost a necessity in contemporary web development makes jQuery an amazing library. Albeit despite its appealing and attractive features, the philosophy of jQuery is not compatible with AngularJS. The fundamental difference between the two is that AngularJS is about architecture of applications whereas jQuery is a library for simplifying “HTML document traversal and manipulation, event handling, animation and Ajax.”
AngularJS allows for the extension of one’s HTML vocabulary for the application whereas jQuery compels the developer to think of existing HTML standards. Therefore, in order to truly comprehend the building of an application using AngularJS, the usage of jQuery must be stopped.
AngularJS is a framework that evolves with the community. By refraining from the conventions described above and understanding the reason why, it is hoped that the mistakes made in the usage of AngularJS are not repeated.
Three ways to pass the command line arguments to node.js
// print process.argv
process.argv.forEach(function (val, index,
console.log(index + ‘: ‘ + val);
This will Genearate,
$ node process-2.js one two=three four
Yes, by using :before and :after, we can achieve this. However, for dynamic data, we may have to use JQUERY.
Only CSS (static text)
There are several ways to handle this situation
1. Don’t Re-Render the Parent View
The simplest is to design a parent view that doesn’t require re-rendering. It has static content and serves as a container of child views. The child view container elements are never re-rendered, so they never go stale.
2. Reassign the Child View’s Element
Another more practical approach is to reassign the child view’s container once the parent view renders. Your view can now re-render appropriately, but its events will still be broken, as they are still stale. This second piece can be fixed with a call to delegate Events.