Skip to content

Instantly share code, notes, and snippets.

View MKRhere's full-sized avatar
😕
In a mid-youth crisis

Muthu Kumar MKRhere

😕
In a mid-youth crisis
View GitHub Profile
function isFloat(int) {
return int % 1 !== 0;
}
function padBinary(string, pad = 7) {
while(string.length < pad) string = "0".concat(string);
return string;
}
if ((typeof window) === "undefined" || !("btoa" in window)) var btoa = v => Buffer.from(v).toString("base64");
if ((typeof window) === "undefined" || !("atob" in window)) var atob = v => Buffer.from(v, "base64").toString();
const toBase64 = btoa;
@coolaj86
coolaj86 / how-to-publish-to-npm.md
Last active June 9, 2024 23:19
How to publish packages to NPM

Getting Started with NPM (as a developer)

As easy as 1, 2, 3!

Updated:

  • Aug, 08, 2022 update config docs for npm 8+
  • Jul 27, 2021 add private scopes
  • Jul 22, 2021 add dist tags
  • Jun 20, 2021 update for --access=public
  • Sep 07, 2020 update docs for npm version