Sourcehunt #4 – Reflection, Authorization, Crons, and more

We skipped January’s Sourcehunt, but we’re back now, ready to boost the stardom of more projects!

Sourcehunt logo

mult1mate/cron-manager [125 ★]

mult1mate/cron-manager is a flexible tasks manager designed for MVC-type applications. It’s used instead of crontab and its purpose is to provide an easy way to manipulate repetitive tasks.

In some ways, it’s similar to Laravel’s scheduler but framework-agnostic and comes with added interactive features which you can explore in the demo.

Continue reading %Sourcehunt #4 – Reflection, Authorization, Crons, and more%


Source: Sitepoint

Launch Your Project Management Career with Two Certifications

Launch your project management career with two essential certifications

The project management industry has been growing fast for the past decade, and it shows no signs of slowing down. We’ll likely see 15.7 million new project management roles created from 2010 to 2010—and one of those could be yours, with the right certifications. Pick up the Project Management Institute PMP & CAPM Training Bundle. It’s just $49—98% off for SitePoint readers.

Learn how to build a project team, estimate the time, money, and human resources required, control costs, reduce project creep, and manage risk. By the time you wrap up the two courses, you’ll be ready to ace your PMP and CAPM certification exams. Whether you’re a consultant who wants to wow new clients, a manager who’s ready for a promotion, or a total beginner looking to get your foot in the door in the industry ASAP, these courses will have something for you.

Get the Project Management Institute PMP & CAPM Training Bundle for just $49!

Continue reading %Launch Your Project Management Career with Two Certifications%


Source: Sitepoint

Get 2TB of Cloud Backup for Life from SkyHub for $50

Get 2TB of cloud backup for life from SkyHub for $50

Shrugging and hoping for the best doesn’t count as a secure data storage solution. SkyHub cloud storage, on the other hand…well, we think the Wall Street Journal said it best when they called SkyHub “online file storage excellence.” Get 2TB of cloud backup for life for just $49.99 at SitePoint Shop.

This SkyHub deal gets you 2TB of automatic backup for your data on up to four devices, including your Mac, PC, iPhone and Android phones, and NAS or DAS external devices. Data stays super secure while still being available to you through the SkyHub dashboard, where you can view image previews, share files, and search for easy lookup. And if you’re wondering how secure SkyHub is, Canon, Epson, Harvard Library, Caldwell Banker, and Acer are just some of the companies that trust their servers.

Get 2TB of cloud backup for life from SkyHub for $49.99 at SitePoint Shop!

Continue reading %Get 2TB of Cloud Backup for Life from SkyHub for $50%


Source: Sitepoint

Preload: What Is It Good For?


  

Preload (spec) is a new web standard aimed at improving performance and providing more granular loading control to web developers. It gives developers the ability to define custom loading logic without suffering the performance penalty that script-based resource loaders incur.

Preload: What is it good for?

A few weeks ago, I shipped preload support in Chrome Canary, and barring unexpected bugs it will hit Chrome stable in mid-April. But what is that preload thing? What does it do? And how can it help you?

The post Preload: What Is It Good For? appeared first on Smashing Magazine.


Source: Smashing Magazine

Web Development Reading List #126: Clever Interfaces, An Open AMP Alternative And The Art Of Slow Growth


  

It’s interesting to see how user experience design advances now that we managed to understand what it means. I think artificial intelligence will become a huge part of user experience over time and that we will spend more time on developing clever integrations to third parties than developing our own “dumb” interfaces. That’s why I find it interesting to see research on how services can use unified interfaces like text messaging apps to become more intelligent. Enjoy your weekend!

Apps and services integrated into text messages. Is this the future of text?

Why reinvent everything and ship your own application when you could use a messaging app as input and output of your API instead? For example, a schedule for the next bus could be delivered to the user via a text, WhatsApp or Telegram message.

The post Web Development Reading List #126: Clever Interfaces, An Open AMP Alternative And The Art Of Slow Growth appeared first on Smashing Magazine.


Source: Smashing Magazine

Introduction to Functional Reactive Programming with RxJS

Before we dive into the topic we have to answer the crucial question: What is reactive programming? As of today, the most popular answer is that reactive programming is programming with concurrent data streams. Most of the time we will find the word concurrent replaced by asynchronous, however, we will see later on that the stream does not have to be asynchronous.

It is easy to see that the “everything is a stream” approach can be applied directly to our programming problems. After all, a CPU is nothing more than a device which processes a stream of information consisting of instructions and data. Our goal is to observe that stream and transform it in case of particular data.

The principles of reactive programming are not completely new to JavaScript. We already have things like property binding, the EventEmitter pattern, or Node.js streams. Sometimes the elegance of these methods comes with decreased performance, overly complicated abstractions, or problems with debugging. Usually, these drawbacks are minimal compared to the advantages of the new abstraction layer. Our minimal examples will, of course, not reflect the usual application, but be as short and concise as possible.

Without further ado, let’s get our hands dirty by playing with The Reactive Extensions for JavaScript (RxJS) library. RxJS uses chaining a lot, which is a popular technique also used in other libraries such as jQuery. A guide to method chaining (in the context of Ruby) is available on SitePoint.

Stream Examples

Before we dive into RxJS we should list some examples to work with later. This will also conclude the introduction to reactive programming and streams in general.

In general, we can distinguish two kinds of streams: internal and external. While the former can be considered artificial and within our control, the latter come from sources beyond our control. External streams may be triggered (directly or indirectly) from our code.

Usually, streams don’t wait for us. They happen whether we can handle them or not. For instance if we want to observe cars on a road, we won’t be able to restart the stream of cars. The stream happens independent of if we observe it or not. In Rx terminology we call this a hot observable. Rx also introduces cold observables, which behave more like standard iterators, such that the information from the stream consists of all items for each observer.

The following images illustrates some external kinds of streams. We see that (formerly started) requests and generally set up web hooks are mentioned, as well as UI events such as mouse or keyboard interactions. Finally, we may also receive data from devices, for example GPS sensors, an accelerometer, or other sensors.

Image showing different types of streams

The image also contained one stream noted as Messages. Messages can appear in several forms. One of the most simple forms is a communication between our website and some other website. Other examples include communication with WebSockets or web workers. Let’s see some example code for the latter.

The code of the worker is presented below. The code tries to find the prime numbers from 2 to 1010. Once a number is found the result is reported.

(function (start, end) {
    var n = start - 1;

    while (n++ < end) {
        var k = Math.sqrt(n);
        var found = false;

        for (var i = 2; !found && i <= k; ++i) {
            found = n % i === 0;
        }

        if (!found) {
            postMessage(n.toString());
        }
    }
})(2, 1e10);

Classically, the web worker (assumed to be in the file prime.js) is included as follows. For brevity we skip checks for web worker support and legality of the returned result.

var worker = new Worker('prime.js');
worker.addEventListener('message', function (ev) {
    var primeNumber = ev.data * 1;
    console.log(primeNumber);
}, false);

More details on web workers and multi-threading with JavaScript can be found in the article Parallel JavaScript with Parallel.js.

Considering the example above, we know that prime numbers follow an asymptotic distribution among the positive integers. For x to ∞ we obtain a distribution of x / log(x). This means that we will see more numbers at the beginning. Here, the checks are also much cheaper (i.e., we receive much more prime numbers per unit of time in the beginning than later on.)

This can be illustrated with a simple time axis and blobs for results:

Ball diagram showing Prime number distribution

A non-related but similar example can be given by looking at a user’s input to a search box. Initially, the user may be enthusiastic to enter something to search for; however, the more specific his request gets the greater the time difference between the key strokes becomes. Providing the ability to show live results is definitely desirable, to help the user in narrowing his request. However, what we do not want is to perform a request for every key stroke, especially since the first ones will be performed very fast and without thinking or the need to specialize.

Continue reading %Introduction to Functional Reactive Programming with RxJS%


Source: Sitepoint

Better WordPress Development Workflow with WordPlate

Composer is a fantastic tool that is widely used in modern PHP development to handle your project dependencies. It helps to install and update all related packages or dependencies of your project. Although it is not primarily used in WordPress core yet, as developers we can still take advantage of Composer to bootstrap our WordPress applications.

For references and documentation on using Composer alongside WordPress, I cannot recommend highly enough Rarst’s Composer site. It is a great resource to learn how Composer can be integrated to WordPress in many different ways. Recently, there has also been a few projects that aim to simplify the WordPress setup using Composer such as WP Starter and WordPlate.

According to the official WordPlate website, WordPlate is described as a:

“WordPress framework built with Laravel and Symfony components. With a familiar setup for every Laravel enthusiast. Following the don’t repeat yourself principle”.

WordPlate

WordPlate is a WordPress boilerplate that takes the idea of managing your WordPress site completely with Composer, and ease up various parts of the development with popular packages from Packagist such as PHP dotenv and Symfony components. The rest of the article will focus on WordPlate, specifically the latest release version of 3.1.0 at the time of writing.

Continue reading %Better WordPress Development Workflow with WordPlate%


Source: Sitepoint

Why Choose Scrum for Web and Mobile Development

A rugby scrum, which is not the same thing as scrum development.

It’s never surprised me that scrum has a bit of a controversial reputation. While some praise scrum for its effective and straightforward approach to software development, there are professional software developers who have staked their reputations on arguing that approaches such as scrum are at best pointless, and at worst detrimental to an effective software development effort.

Scrum may well have encouraged such heated debate, not because of anything intrinsic to scrum itself, but rather due to misconceptions and misapplications of the terminology and the technology that have grown up around scrum. And if your team is working on web and mobile development projects, scrum may be the best possible solution out there for managing your projects.

So What Is Scrum?

[author_more]

Scrum is one of a family of approaches to organizing software projects that fit together under the umbrella of agile. Other agile techniques include kanban and extreme programming. All of these approaches share a few common principles about how people should work together in software development, and how to optimize that process, such as:

  • Delighting the customer
  • Delivering working software frequently
  • Business people and developers working together
  • Measuring real results based on work that is completed
  • Allowing teams to self-organize
  • Reflecting regularly on what’s working and what isn’t

In particular, scrum is optimized for teams working on projects that can be broken down into complete slices of functionality able to be delivered within a fixed and regular time frame of usually one or two sustainable work weeks, known as sprints in scrum. Scrum uses the term stories to describe those slices of functionality, and strives to improve the team’s ability to estimate how much effort would go into completing a story.

Unlike traditional software development approaches, often lumped together under the label waterfall, scrum doesn’t involve long and detailed requirements documents full of specifications crafted by product managers that all need to be spelled out before the team can get started working.

Scrum is flexible enough to allow a team to get started based on just enough stories to keep them busy for a couple of weeks. In that time, if there’s new user feedback, the market changes, new information comes up from outside or inside the company, or the technology underlying the product shifts, new stories can be introduced and worked on for the next couple of weeks.

Scrum also favors regular face-to-face communication over detailed specifications. This is usually helped along by having every member of the team stand up in a group daily and report on what they’ve done the previous day, what they’re planning to do the current day, and whether they have any blockers. Scrum also recommends other regular face-to-face meetings, called rituals, for planning, demonstrating, and doing a retrospective every sprint.

While the prospect of a daily meeting may sound off-putting to a lot of developers, it’s important to remember that these are all finely tuned scrum rituals managed by a scrum master, with fixed times and clear agendas. For example, the daily standup should never take longer than 15 minutes.

Roles such as scrum master and product owner are also defined within scrum. And you may have noticed that the vocabulary of scrum sounds a little funky for a professional technical environment. That’s kind of the point. Scrum defines roles, rituals, and artifacts in such a way that you can’t confuse them easily with other approaches.

Continue reading %Why Choose Scrum for Web and Mobile Development%


Source: Sitepoint

5 Ways to Offer a Better UX to Disabled Users

Across the population, spatial reasoning abilities vary widely from person to person. However, it’s fair to say that designers generally have above-average abilities to visualize and understand how websites work. That’s often why we are drawn to design in the first place. So does that make us ideal candidates for designing websites? Well, actually no. […]

Continue reading %5 Ways to Offer a Better UX to Disabled Users%


Source: Sitepoint

Easily Allow File Uploads with Rails and Refile

Enabling image uploading as a feature in your web application cannot be underestimated. Especially when it is an application that has to do with users having a profile. There are lots of gems available out there to help you handle this in a few lines of code, and most of them have been covered here on SitePoint Ruby.

They include:

In this tutorial, we will be learning how to enable image uploading in Rails using Refile. As written on Refile’s github page, it is a modern file upload library for Ruby applications. It is simple, yet powerful.

Continue reading %Easily Allow File Uploads with Rails and Refile%


Source: Sitepoint