Articles
I can’t imagine building a modern JavaScript application or website without using any kind of build system. Recently I’ve used Grunt in several projects. There is also Gulp, Broccoli and probably many more.
I’ve asked myself if the building process can’t be done in a different way. Why do I need extra layer like Grunt? What would be the benefits of having build system created on your own? Why not just using NodeJS and npm packages? The think is that behind Grunt there are also the same packages as you’d use without Grunt.
The problem
A[……]
Read more
Really worth it to listen, especially for those people who’s interviewing other people for JavaScript developer position.[……]
Read more
Recently I wanted to import just .css
file into .scss
directly. This is not available directly in scss. However, you can import it when you change the extension from .css
to .scss
. While this solves generally problem then working with Bower components it becomes little bit painful when you’d need copy and change the name every time you install/upgrade the package.
In my particular case I wanted to include normalize.css
in my scss files and I didn’t want to do manually copy&rename every time I install/upgrade normalize.css from Bower. So, in[……]
Read more
Recently I wanted to update each dependency in package.json
to the latest version. I didn’t want to do that manually. After some research I found that npm package npm-check-updates (Find newer versions of dependencies than what your package.json or bower.json allows) comes in handy.
Here are the steps which I did:
$ npm install -g npm-check-updates
$ npm-check-updates -u
$ npm install
-u
option means upgrade your package.json
automatically. Here is the result of running npm-check-updates
:

Update
Thanks to Eric Elliot tweet[……]
Read more
There could be a situation where we want to add new path to the Path
environment variable using batch script. Let’s say you have a directory build/commands
and you want to add this path to the Windows Path
environment variable.

Let’s then create small batch script setpath.bat
which will do few things:
- be able to execute with UAC privilege elevation
- read the current directory path so that you don’t have to worry about specifying full path
- add specified path to the end of
PATH
configuration
- check, if at the end of
PATH
configur[……]
Read more
Eric Elliot sent a tweet with a question: What do you think is the biggest / most common mistake software developers make?. I think it’s worth it to collect them here into one list.
- technology is not politically neutral
- underestimating the time something will take
- deferring technical debt
- “copy & paste”
- coming up with patterns, just for the sake of patterns; solving real life problems is what they should do
- chronically adopting new tools and frameworks, and leaving no time to learn or embrace the fundamentals
- not testing
- dev[……]
Read more
So, I started playing with EmberJS framework. However, build times on Windows are longer than on Linux or Mac OS X. Much of that penalty is not because of node or ember-cli, but because of Windows services monitoring filesystem. So, I have installed npm package npm install --save-dev ember-cli-windows-addon
in order to configure Windows to work effectively with Ember build. Then, to start the automatic configuration, I run ember windows
and got error message:
Configuration Error: File C:\Sources\ember\node_modules\ember-cli-windows-addon\no[……]
Read more
Currently I am using both Grunt tasks grunt-sass
and grunt-contrib-sass
to compile sass (strictly scss). The first one is faster than second one, but second one generating source maps that just works. Unfortunately grunt-sass
source maps somehow doesn’t work properly and browsers can’t use them.
I got an error message today and I’d like to share simple solution to that. The scss code more or less looks like:
@include example() {
[...]
@import 'part1';
@import 'part2';
[...]
}
Above code is compiled fine using grunt-sass
, but grunt[......]
Read more
Wondering what’s the userAgent
for Edge (Spartan)? Here we go:
Mozilla/5.0 (Windows Phone 10.0; Android 4.2.1; NOKIA; Lumia 730 Dual SIM) Apple WebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Mobile Safari/537.36 Edge/12.0
You still think you should use browser sniffing? :-)[……]
Read more
If you are curious what’s the navigator.userAgent
for the Chrome browser on ChromeOS then here we go:
Mozilla/5.0 (X11; CrOS x86_64 6310.68.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.96 Safari/537.36
[……]
Read more
Pagination