Skip to content

Instantly share code, notes, and snippets.

View hoanganh25991's full-sized avatar

Anh Le hoanganh25991

  • https://originallyus.sg
  • Vietnam
View GitHub Profile
@branneman
branneman / better-nodejs-require-paths.md
Last active January 30, 2024 04:32
Better local require() paths for Node.js

Better local require() paths for Node.js

Problem

When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:

const Article = require('../../../../app/models/article');

Those suck for maintenance and they're ugly.

Possible solutions

@HarishChaudhari
HarishChaudhari / country-code-to-currency-code-mapping.csv
Last active March 17, 2024 14:03
Country, Country Code, Currency code mapping in CSV format Taken from https://gist.github.com/304261 Contains 249 countries.
Country CountryCode Currency Code
New Zealand NZ New Zealand Dollars NZD
Cook Islands CK New Zealand Dollars NZD
Niue NU New Zealand Dollars NZD
Pitcairn PN New Zealand Dollars NZD
Tokelau TK New Zealand Dollars NZD
Australian AU Australian Dollars AUD
Christmas Island CX Australian Dollars AUD
Cocos (Keeling) Islands CC Australian Dollars AUD
Heard and Mc Donald Islands HM Australian Dollars AUD