What is `Vala` (programming language)? an `object-oriented programming language` that generates `C` code

What is Vala (programming language)? an object-oriented programming language that generates C code Elementary OS, a Linux distribution with a desktop environment programmed mostly in Vala Vala (programming language) – Wikipedia Vala is an object-oriented programming language with a self-hosting compiler that generates C code and uses the GObject system. Vala is syntactically similar to…

Read More

Babel: Why aren’t files in `node_modules` being transformed with Browserify?

babel/babelify: Browserify transform for Babel Why aren’t files in node_modules being transformed with Browserify? https://github.com/babel/babelify#why-arent-files-in-node_modules-being-transformed This is the default browserify behavior. A possible solution is to add: { “browserify”: { “transform”: [“babelify”] } } to the root of all your modules package.json that you want to be transformed. If you’d like to specify options then…

Read More

How to replace `Bower` to `Yarn` with `Yarn Workspaces`

How to replace Bower to Yarn with Yarn Workspaces Example: mean-project‘s structure | mean-project/ | —- package.json <—– `Node.js Server & development packages’ list` | —- bower.json <—– `Web Client packages’ list` | —- node_modules/ | —————– express/ <— `’package.json’ install dependencies` | —————– grunt/ <— `’package.json’ install devDependencies` | | —- client/ | ———–…

Read More

How to show hidden files(in `.gitignore`, etc.) Atom sidebar

How to show hidden files(in .gitignore, etc.) Atom sidebar Atom(https://atom.io/) is My Favorite Developing Editor currently. Previously, I used the Eclipse Java Editor, SubLime Text, and WebStorm Web Editor, etc. How to show hidden files Atom sidebar – Panayiotis Georgiou – Medium How to show hidden files Atom sidebar Alternatively, if you feel that your…

Read More

What are the `ES6` modules and `CommonJS` modules?

Read Setting up ES6 | Leanpub What are the ES6 modules and CommonJS modules? This chapter examines how Babel ensures that code it transpiles interoperates properly with normal CommonJS modules. Consult chapter “Modules” in “Exploring ES6” for more information on ES6 modules. 7.1 ES6 modules vs. CommonJS modules 7.1.1 ECMAScript 6 modules Default export (single…

Read More

What is difference between `module.exports` and `export` in node.js?

ES Modules: Using Named Exports as the Default Export https://medium.com/@timoxley/named-exports-as-the-default-export-api-670b1b554f65 // in `cow.js` : export function speak () { return ‘moo’ } To use a named export, we can import it directly into our code: // in `import-named.js` : import { speak } from ‘./cow’; speak() // => ‘moo’ Aliasing named imports You can assign…

Read More

Git – Undoing Changes: git checkout git revert git reset git clean

Git Undoing Changes git checkout git revert git reset git clean https://www.atlassian.com/git/tutorials/undoing-changes Whereas reverting is designed to safely undo a public commit, git reset is designed to undo local changes. Because of their distinct goals, the two commands are implemented differently: resetting completely removes a changeset, whereas reverting maintains the original changeset and uses a…

Read More

Extract directory, filename, and extension in Bash shell

Extract directory, filename, and extension in Bash shell https://stackoverflow.com/questions/965053/extract-filename-and-extension-in-bash $> FILE_PATH=”dir/example.tar.gz” $> FILE=”example.tar.gz” $> dirname $FILE_PATH dir $> dirname $FILE . $> basename $FILE_PATH example.tar.gz $> basename $FILE example.tar.gz # ——————————- # dir/example.tar(.gz) : $> echo “${FILE_PATH%.*}” dir/example.tar # dir/example(.tar(.gz)) : $> echo “${FILE_PATH%%.*}” dir/example # example.tar(.gz) : $> echo “${FILE%.*}” example.tar # example(.tar(.gz)) :…

Read More

Using Babel 6 + grunt to work with ES6 – how to transform require statements?

Using Babel 6 + grunt to work with ES6 – how to transform require statements? https://stackoverflow.com/questions/41067220/using-babel-grunt-to-work-with-es6-how-to-transform-require-statements Browserify will handle the import bindings for the ES6 modules. Also a package named babelify will help to handle your babel browserify transform. The following seems to work well: Use babel-cli instead of babel. Step 1. It’s worth noting…

Read More

`bluebird@3.5.1`: MongoDB `mongoose@4.13.7` `Promises` library

bluebird@3.5.1: MongoDB mongoose@4.13.7 Promises library > Warning: a promise was created in a handler > at internal/process/next_tick.js:180:9 but was not returned from it, > see http://goo.gl/rRqMUw > at model.Query.ret [as execAsync] > (eval at makeNodePromisifiedEval > (/home/bike/github/SmartPlug-Foodtruck.kr/node_modules/bluebird/js/release/promisify.js:184:12), <anonymous>:8:21) > mongoose Promises : bluebird http://mongoosejs.com/docs/promises.html Built-in Promises Mongoose async operations, like .save() and queries, return Promises/A+…

Read More