Gangmax Blog


What Is This in JavaScript?

| Comments

From here and here.

What is this?

The JavaScript this keyword refers to the object it belongs to.

It has different values depending on where it is used:

In a method, this refers to the owner object.

Alone, this refers to the global object.

In a function, this refers to the global object.

In a function, in strict mode, this is undefined.

In an event, this refers to the element that received the event.

Methods like call(), and apply() can refer this to any object.

ElasticSearch, Miniconda and Jupyter

| Comments

This is a guide how to use ElasticSearch with Python and Jupyter.

To make the Jupyter works on my environment, I want to create a “miniconda” virtual environment, which caused error with “pyenv”. Here is the instructions how to make it work.

Pouring Homebrew

| Comments

When running the ”brew” command to install a formula, I always see the “Pouring …” output in console. What does that mean? So I googled “pouring homebrew” and found this. Interesting…