From 1564c4e24759f67d21b336d8cfc07fc3ba40d485 Mon Sep 17 00:00:00 2001 From: Subhajit Sahu Date: Wed, 12 Apr 2023 21:54:29 +0530 Subject: [PATCH] :bug: docs: update require name --- .github/workflows/ci.yml | 11 +- README.md | 44 +- package-lock.json | 4551 ++++++-------------------------------- package.json | 20 +- src/index.ts | 4 +- tests/index.test.ts | 8 +- wiki | 2 +- 7 files changed, 706 insertions(+), 3934 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8a878aa..244db5c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,6 +7,9 @@ on: tags: - '!*' # Do not execute on tags env: + NAME: ${{vars.NAME}} + EMAIL: ${{vars.EMAIL}} + NPM_TOKEN: ${{secrets.NPM_TOKEN}} GITHUB_TOKEN: ${{secrets.GH_TOKEN}} CC_TEST_REPORTER_ID: ${{secrets.CC_TEST_REPORTER_ID}} FORCE_COLOR: 1 @@ -55,8 +58,7 @@ jobs: - uses: actions/setup-node@v2 with: node-version: 18.x - - run: git clone https://${GITHUB_TOKEN}@github.com/nodef/deploy "$HOME/deploy" - - run: bash "$HOME/deploy/setup.sh" + - uses: nodef/git-config.action@v1.0.0 - run: npm i -g typescript typedoc - run: npm ci - run: npm run publish-docs @@ -71,8 +73,9 @@ jobs: - uses: actions/setup-node@v2 with: node-version: 18.x - - run: git clone https://${GITHUB_TOKEN}@github.com/nodef/deploy "$HOME/deploy" - - run: bash "$HOME/deploy/setup.sh" + - uses: nodef/npm-config.action@v1.0.0 + with: + entries: access = public - run: npm i -g typescript rollup typedoc browserify terser - run: npm ci - run: npm run publish-packages diff --git a/README.md b/README.md index 4c639cb..4a1591a 100644 --- a/README.md +++ b/README.md @@ -1,22 +1,23 @@ -A collection of ways for transforming functions.
+A **function** is a *set of statements* that *performs a task* or *calculates a value*.
πŸ“¦ [Node.js](https://www.npmjs.com/package/extra-function), 🌐 [Web](https://www.npmjs.com/package/extra-function.web), πŸ“œ [Files](https://unpkg.com/extra-function/), πŸ“° [JSDoc](https://nodef.github.io/extra-function/), πŸ“˜ [Wiki](https://github.com/nodef/extra-function/wiki/). -A **function** is a **set of statements** that *performs a task* or *calculates* -*a value*. It can accept some **parameters**, and may define some **local** -**variables** necessary for performing the desired *operation*. These *parameters* -and *local variables* are contained in the **scope of the function**, and -*cannot* be accessed from the *outside*. However, a function can access -variables *external to itself* (as long as they are not *overridden*), such as -*global variables* or *variables* in the scope this function is *encapsulated* -*in*. A **nested function** can access *free variables* that are defined in -*outer scopes*, even when it is being *invoked* **away** from where it is -*defined*. It does this by **capturing** the *free variables* (by *reference*) -into a **closure** [(1)]. *Closure*, *arrow functions*, and more, are -*functional language features* based on [lambda calculus]. +Functions are one of the fundamental building blocks in JavaScript. It is +similar to a procedureβ€”a set of statements that performs a task or calculates a +value [(1)]. It can accept some **parameters**, and may define some **local** +**variables** necessary for performing the desired *operation*. These +*parameters* and *local variables* are contained in the **scope of the** +**function**, and *cannot* be accessed from the *outside*. However, a function can +access variables *external to itself* (as long as they are not *overridden*), +such as *global variables* or *variables* in the scope this function is +*encapsulated in*. A **nested function** can access *free variables* that +are defined in *outer scopes*, even when it is being *invoked* **away** from +where it is *defined*. It does this by **capturing** the *free variables* (by +*reference*) into a **closure** [(1)]. *Closure*, *arrow functions*, and more, +are *functional language features* based on [lambda calculus]. This package includes a number of methods to *transform functions*. This enables you to obtain a desired function by transforming the behavior of existing @@ -49,8 +50,9 @@ metadata (about) information on a function. To attach a `this` to a function, use [bind]. A few generic functions are also included: [NOOP], [FALSE], [TRUE], [IDENTITY], [COMPARE], [ARGUMENTS]. -This package is available in both *Node.js* and *Web* formats. The web format is -exposed as `extra_function` standalone variable and can be loaded from [jsDelivr CDN]. +This package is available in *Node.js* and *Web* formats. To use it on the web, +simply use the `extra_function` global variable after loading with a `