open-index/open-npm huggingface dataset:
npm package: @natlibfi/melinda-record-import-commons
Description: Shared modules for microservices of Melinda record batch import system
Author: The National Library of Finland
Latest version: 13.0.3

# Shared modules for microservices of Melinda record batch import system [![NPM Version](https://img.shields.io/npm/v/@natlibfi/melinda-record-import-commons.svg)](https://npmjs.org/package/@natlibfi/melinda-record-import-commons) [![Build Status](https://travis-ci.org/NatLibFi/melinda-record-import-commons.svg)](https://travis-ci.org/NatLibFi/melinda-record-import-commons) [![Test Coverage](https://codeclimate.com/github/NatLibFi/melinda-record-import-commons/badges/coverage.svg)](https://codeclimate.com/github/NatLibFi/melinda-record-import-commons/coverage)

Shared modules for microservices of Melinda record batch import system

## License and copyright

Copyright (C) 2018-2026 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/melinda-record-match-validator
Description: Validates if two records matched by melinda-record-matching can be merged and sets merge priority
Author: The National Library of Finland
Latest version: 3.2.2

# melinda-record-match-validator
Validates if 2 records matched by melinda-record-matching can be merged and sets merge priority.

**default** version for matchValidator:
- comparisonTasks suited for automatic import merge of an incoming record and existing database record
- runs comparisonTasks (that are defined usable for import merge) until first point of failure
- returns result for first point of failure, or message for all comparisonTasks not failing / not giving preference change information

**matchValidationForMergeUI** version for matchValidator:
- comparisonTasks suited for internal, manual merge of two database records
- runs all comparisonTasks (that are defined usable for internal, manual merge)
- returns filtered array of failed and edited validation results and preference results changing the preference
- divides failed validation results for manual merge as errors (records cannot be merged) or warnings (user should check whether they actually want to merge records that are not automatically mergable)
- returns empty array, if there are no failures / preference changes

## License and copyright

Copyright (c) 2022-2026 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/melinda-record-matching
Description: Melinda record matching modules for Javascript
Author: The National Library of Finland
Latest version: 5.0.4

# Melinda record matching modules for Javascript [![NPM Version](https://img.shields.io/npm/v/@natlibfi/melinda-record-matching.svg)](https://npmjs.org/package/@natlibfi/melinda-record-matching)

## License and copyright

Copyright (c) 2020-2026 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/melinda-rest-api-client
Description: Javascript client for Melinda REST API
Author: The National Library of Finland
Latest version: 6.0.3

# Melinda's rest api client [![NPM Version](https://img.shields.io/npm/v/@natlibfi/melinda-rest-api-client.svg)](https://npmjs.org/package/@natlibfi/melinda-rest-api-client)

## License and copyright

Copyright (c) 2020-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/melinda-ui-commons
Description: Common modules for Melinda UI applications
Author: The National Library of Finland
Latest version: 6.0.0

# Common modules for Melinda UI applications 
[![NPM Version](https://img.shields.io/npm/v/@natlibfi/melinda-ui-commons.svg)](https://npmjs.org/package/@natlibfi/melinda-ui-commons)

Common modules for Melinda UI applications:

[melinda-ui-artikkelit](https://github.com/NatLibFi/melinda-ui-artikkelit)

[melinda-ui-cyrillux](https://github.com/NatLibFi/melinda-ui-cyrillux)


## License and copyright

Copyright (C) 2015-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/oai-pmh-client
Description: OAI-PMH Javascript client library
Author: The National Library of Finland
Latest version: 4.0.0

# OAI-PMH Javascript client library [![NPM Version](https://img.shields.io/npm/v/@natlibfi/oai-pmh-client.svg)](https://npmjs.org/package/@natlibfi/oai-pmh-client)

# Usage
## Retrieve all records
```js
import createClient from '@natlibfi/oai-pmh-client';
const client = createClient({url: 'https://foo.bar', metadataPrefix: 'marc'});

client.listRecords()
  .on('record', record => processRecord(string))
  .on('end', () => endProcessing())
  .on('error', err => handleError(err));
```
## Retrieve records only from the first response
```js
import createClient from '@natlibfi/oai-pmh-client';
const client = createClient({url: 'https://foo.bar', metadataPrefix: 'marc', retrieveAll: false});

client.listRecords()
  .on('record', record => processRecord(string))
  .on('end', resumptionToken => endProcessing(resumptionToken))
  .on('error', err => handleError(err));
```

And then use the returned resumption token:
```js
client.listRecords({resumptionToken})
  .on('record', record => processRecord(string))
  .on('end', resumptionToken => endProcessing(resumptionToken))
  .on('error', err => handleError(err));
```

If you need oai-pmh responses
```js
client.listRecords()
  .on('oaiPmhResponse', responseText => processResponse(responseText));
```


# Configuration
## Client creation options
- **url**: The URL of the OAI-PMH service.
- **metadataPrefix**: Metadata prefix to use. **Mandatory**.
- **set**: Set to use.
- **metadataFormat**: Format of the metadata argument in **record** event. Defaults to **string** (See export **metadataFormats**)
- **retrieveAll**: Whether to retrieve all records or just from the first response. If **false**, the **end** event returns the resumptionToken.
- **filterDeleted**: Whether to filter out deleted records. Defaults to **false**.
## listRecords options:
- **metadataPrefix**: Override default metadata prefix.
- **set**: Override default set.
- **resumptionToken**: Resumption to use to resume the harvesting from.
## Cli env options
- **Check example.env**

## License and copyright

Copyright (c) 2020, 2023-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/passport-keycloak
Description: Passport strategy for Keycloak JWT
Author: The National Library of Finland
Latest version: 3.0.6

# Passport strategy for Keycloak JWT

Passport strategy for Keycloak JWT. This module has the following features:
- Written in modern day Javascript/ECMAscript
- Supports HTTP Bearer authentication using Keycloak JWT as bearer tokens
- Verifies token locally (i.e. does not use network calls to introspect endpoint, public keys are fetched from jwks endpoint and cached after first use)

## Strategies
This module provides the following Passport strategies.

### Bearer
HTTP Bearer authentication works by using the token generated after signing in to Keycloak for gaining access to the defined resources.

Does **not** allow configuration for ignoring token expiration.

### Usage

#### ES modules
```javascript
import {KeycloakStrategy} from '@natlibfi/passport-keycloak'
```

### Configuration
Configuration of the strategy needs to be passed to the class constructor as object.

- **algorithms (required):** Algorithm for decoding jwt
- **audience (required):** Audience of jwt
- **issuer (required):** Issuer of jwt
- **jwksUrl (required):** JWKS url to fetch public keys from


## License and copyright

Copyright (c) 2023-2024 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT license**
npm package: @natlibfi/passport-melinda-aleph
Description: Passport authentication strategy for Melinda using Aleph credentials
Author: The National Library of Finland
Latest version: 4.0.0

# Passport authentication strategy for Melinda using Aleph credentials [![NPM Version](https://img.shields.io/npm/v/@natlibfi/passport-melinda-aleph.svg)](https://npmjs.org/package/@natlibfi/passport-melinda-aleph)

## License and copyright

Copyright (c) 2018-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/passport-melinda-crowd
Description: Passport authentication strategy for Melinda using Crowd or local files
Author: The National Library of Finland
Latest version: 3.0.14

# Passport authentication strategy for Melinda using Crowd or local files [![NPM Version](https://img.shields.io/npm/v/@natlibfi/passport-melinda-crowd.svg)](https://npmjs.org/package/@natlibfi/passport-melinda-crowd)

## License and copyright

Copyright (c) 2018-2020, 2023-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/passport-melinda-jwt
Description: Passport authentication strategy for Melinda using JWT tokens
Author: The National Library of Finland
Latest version: 3.0.0

# Passport authentication strategy for Melinda using jwt tokens

Melinda implementation of passport + jwt token authorization

## How to implement in server side

### Create JWT token
``` javascript
import {generateJwtToken} from '@natlibfi/passport-melinda-jwt';
const token: generateJwtToken(payload, {
  secretOrPrivateKey,
  issuer,
  audience,
  algorithm
});
```
* secretOrPrivateKey: secret
* issuer: String value of issuer
* audience: String value of audience
* algorithm: encryption method default: 'HS512'


### Check JWT token
``` javascript
import MelindaJwtStrategy, {verify, jwtFromRequest} from '@natlibfi/passport-melinda-jwt';

passport.use(new MelindaJwtStrategy({
  secretOrKey
  issuer,
  audience,
  algorithms,
  jwtFromRequest
}, verify));
```
* secretOrKey: secret
* issuer: String value of issuer
* audience: String value of audience
* algorithms: String array, e.g. ['HS512']
* jwtFromRequest: Function that gets token from request (Default contained in this repository)
* verify: Function to verify token content (Default contained in this repository)


## How to implement in client side
``` javascript
headers: {
  Authorization: token,
}
```
* Send token as authorization header in requests

## License and copyright

Copyright (c) 2021-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT** or any later version.
npm package: @natlibfi/passport-natlibfi-keycloak
Description: Passport authentication strategy for National Library of Finland using Keycloak or local files
Author: The National Library of Finland
Latest version: 3.0.6

# Passport authentication strategy for National Library of Finland using Keycloak or local files

## License and copyright

Copyright (c) 2023-2025 **University Of Helsinki (The National Library Of Finland)**

This project's source code is licensed under the terms of **MIT license**
npm package: @natlibfi/sfs-4900
Description: Transliteration from cyrillic (Russian, Ukrainian) text to latin (Finnish) as defined in the SFS-4900 standard
Author: The National Library of Finland
Latest version: 2.0.0

# SFS 4900 based transliteration from Russian and Ukranian to Finnish

## Installation

```
npm install sfs-4900
```

## Usage

```
var converter = require('sfs-4900');

var conversion = converter.convertToLatin('Чайковский, Гоголь'); // defaults to russian

// Second argument can be used to specify language code: 'rus' or 'ukr':
var ukrainianConversion = converter.convertToLatin('Гоголь', 'ukr');



console.log(conversion);
/* prints:
{
 'from': 'Чайковский, Гоголь',
 'result': 'Tšaikovski, Gogol',
 'warnings': []
}
*/


console.log(ukrainianConversion);
/* prints:
{
 'from': 'Гоголь',
 'result': 'Hohol',
 'warnings': []
}
*/
```

Warnings include notes on characters that were not converted.

## See also

- https://fi.wikipedia.org/wiki/Ven%C3%A4j%C3%A4n_translitterointi

- https://fi.wikipedia.org/wiki/Ukrainan_translitterointi
npm package: @natmach/random-generator-id
Description: Simple package generating random IDs - can include uppercase letters, lowercase letters and numbers.
Latest version: 1.0.3

## General info

Simple package generating random IDs - can include uppercase letters, lowercase letters and numbers.

## Setup

To use this package, install it using:

$ npm install @natmach/random-generator-id

or

$ yarn add @natmach/random-generator-id
npm package: @natmri/bilicli-napi-darwin-arm64
Description: This is the **aarch64-apple-darwin** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-darwin-arm64`

This is the **aarch64-apple-darwin** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-linux-arm-gnueabihf
Description: This is the **armv7-unknown-linux-gnueabihf** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-linux-arm-gnueabihf`

This is the **armv7-unknown-linux-gnueabihf** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-linux-arm64-gnu
Description: This is the **aarch64-unknown-linux-gnu** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-linux-arm64-gnu`

This is the **aarch64-unknown-linux-gnu** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-linux-arm64-musl
Description: This is the **aarch64-unknown-linux-musl** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-linux-arm64-musl`

This is the **aarch64-unknown-linux-musl** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-linux-x64-gnu
Description: This is the **x86_64-unknown-linux-gnu** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-linux-x64-gnu`

This is the **x86_64-unknown-linux-gnu** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-linux-x64-musl
Description: This is the **x86_64-unknown-linux-musl** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-linux-x64-musl`

This is the **x86_64-unknown-linux-musl** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-win32-arm64-msvc
Description: This is the **aarch64-pc-windows-msvc** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-win32-arm64-msvc`

This is the **aarch64-pc-windows-msvc** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-win32-ia32-msvc
Description: This is the **i686-pc-windows-msvc** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-win32-ia32-msvc`

This is the **i686-pc-windows-msvc** binary for `@natmri/bilicli-napi`
npm package: @natmri/bilicli-napi-win32-x64-msvc
Description: This is the **x86_64-pc-windows-msvc** binary for `@natmri/bilicli-napi`
Latest version: 0.0.2

# `@natmri/bilicli-napi-win32-x64-msvc`

This is the **x86_64-pc-windows-msvc** binary for `@natmri/bilicli-napi`
npm package: @natnaeltulip/tiny
Description: Removes all spaces from a string
Latest version: 2.0.0

# @natnaeltulip/tiny

[![npm (scoped)](https://img.shields.io/npm/v/@natnaeltulip/tiny.svg)](https://github.com/natigk/tiny)
[![npm bundle size (minified)](https://img.shields.io/bundlephobia/min/@natnaeltulip/tiny.svg)](https://github.com/natigk/tiny)

Removes all spaces from a string.

## Install
```
$npm install @natnaeltulip/tiny
```

## usage
```js
const tiny = require("@natnaeltulip/tiny");

tiny("So much space!");
//=> "Somuchspace!"

tiny(1534);
//=>Uncaught TypeError: Tiny wants a string!
//   at tiny(<anonymous>:2:41)
//   at <anonymous>:1:1
```
npm package: @natnt2000/nestjs-schematics
Description: Nest - modern, fast, powerful node.js web framework (@schematics)
Latest version: 8.0.12

<p align="center">
  <a href="http://nestjs.com/" target="blank"><img src="https://nestjs.com/img/logo-small.svg" width="120" alt="Nest Logo" /></a>
</p>

  <p align="center">A progressive <a href="http://nodejs.org" target="blank">Node.js</a> framework for building efficient and scalable server-side applications.</p>
    <p align="center">
<a href="https://www.npmjs.com/~nestjscore"><img src="https://img.shields.io/npm/v/@nestjs/schematics.svg" alt="NPM Version" /></a>
<a href="https://www.npmjs.com/~nestjscore"><img src="https://img.shields.io/npm/l/@nestjs/schematics.svg" alt="Package License" /></a>
<a href="https://www.npmjs.com/~nestjscore"><img src="https://img.shields.io/npm/dm/@nestjs/schematics.svg" alt="NPM Downloads" /></a>
  <a href="https://coveralls.io/github/nestjs/nest?branch=master" target="_blank"><img src="https://coveralls.io/repos/github/nestjs/nest/badge.svg?branch=master#9" alt="Coverage" /></a>
<a href="https://discord.gg/G7Qnnhy" target="_blank"><img src="https://img.shields.io/badge/discord-online-brightgreen.svg" alt="Discord"/></a>
<a href="https://opencollective.com/nest#backer" target="_blank"><img src="https://opencollective.com/nest/backers/badge.svg" alt="Backers on Open Collective" /></a>
<a href="https://opencollective.com/nest#sponsor" target="_blank"><img src="https://opencollective.com/nest/sponsors/badge.svg" alt="Sponsors on Open Collective" /></a>
  <a href="https://paypal.me/kamilmysliwiec" target="_blank"><img src="https://img.shields.io/badge/Donate-PayPal-ff3f59.svg"/></a>
  <a href="https://twitter.com/nestframework" target="_blank"><img src="https://img.shields.io/twitter/follow/nestframework.svg?style=social&label=Follow"></a>

## Description

The Nest CLI is a command-line interface tool that helps you to initialize, develop, and maintain your Nest applications. It assists in multiple ways, including scaffolding the project, serving it in development mode, and building and bundling the application for production distribution. It embodies best-practice architectural patterns to encourage well-structured apps. Read more [here](https://docs.nestjs.com/cli/overview).

## Installation

```bash
$ npm install -g @nestjs/schematics
```

## Usage

Learn more in the [official documentation](https://docs.nestjs.com/).

## Stay in touch

- Website - [https://nestjs.com](https://nestjs.com/)
- Twitter - [@nestframework](https://twitter.com/nestframework)

## License

Nest is [MIT licensed](LICENSE).
npm package: @natoune/glfw-js
Description: The N-API bindings for GLFW
Author: Artem Kunets
Latest version: 0.0.6

# glfwJS

The N-API bindings for [GLFW](https://www.glfw.org/) multi-platform library for OpenGL, OpenGL ES and Vulkan development on the desktop. It provides a simple API for creating windows, contexts and surfaces, receiving input and events.

## Example

```js
if (!glfwInit()) {
  process.exit(1);
}

const window = glfwCreateWindow(kWidth, kHeight, "Simple example", null, null);
if (!window) {
  glfwTerminate();
  process.exit(1);
}
glfwMakeContextCurrent(window);

glfwSwapInterval(1);
glfwSetKeyCallback(window, key_callback);

function drawLoop() {
  if (!glfwWindowShouldClose(window)) {
    setTimeout(drawLoop, 0);
  } else {
    glfwDestroyWindow(window);
    glfwTerminate();
    process.exit(0);
  }

  glfwSwapBuffers(window);
  glfwPollEvents();
}
drawLoop();
```

## Documentation

The documentation for the latest version is available [here](https://natoune.github.io/glfwJS/).
npm package: @natoune/nodegl
Description: OpenGl 1.1 Bindings for NodeJS
Author: EnzoAlbornoz
Latest version: 1.1.1

<p align="center">
  <img width="100" src="./.github/images/nodegl.png" alt="NodeGL Logo">
</p>

# NodeGL - OpenGL bindings for Node.JS

This project ports OpenGL C/C++ core calls to Node.JS using N-API.
All callable functions in `gl.h` are binded, including
functions that depend on pointers or non-javascript sized variables
such as float, short and byte.
This is possible by using the Buffer object of Node, which exports its
data as a pointer, unlike a normal JS object or JS arrays (with getters).

# Dependencies

- Linux (For now, only linux headers are used on this project)
- OpenGL Headers
- CMake (Minimum v3)
- GCC or Clang

# Installing


Using Npm:
```
npm install nodegl
```
Using Yarn:
```
yarn add nodegl
```

# Usage

This package focuses on having only OpenGL bindings, GLUT or GLFW are not included, so you
will need some context initializer. The example below uses a [GLFW port](https://github.com/Reon90/glfwJS) that appears on the ports list of the library's website.

```javascript
// Import Libs
const glfw = require("glfw-n-api");
const gl = require("nodegl");
// Setup Code
async function main() {
	// Init GLFW
	if (!glfw.glfwInit()) {
		glfw.glfwTerminate();
		process.exit(1);
	}
	// Define Constants
	const WINDOW_WIDTH = 600;
	const WINDOW_HEIGHT = 600;
	// Create Window
	const window = glfw.glfwCreateWindow(
		WINDOW_WIDTH,
		WINDOW_HEIGHT,
		"OpenGLNode",
		null,
		null
	);
	if (!window) {
		glfw.glfwTerminate();
		process.exit(1);
	}
	// Get Buffer Size
	glfw.glfwSetFramebufferSizeCallback(window, (window, fbW, fbH) => {
		gl.glViewport(0, 0, fbW, fbH);
		gl.glMatrixMode(gl.GL_PROJECTION);
		gl.glLoadIdentity();
	});
	// Set Current GL Context
	glfw.glfwMakeContextCurrent(window);
	// Pre Loop
	gl.glClearColor(0.0, 0.0, 0.0, 1.0);
	gl.glMatrixMode(gl.GL_PROJECTION);
	gl.glLoadIdentity();
	gl.glOrtho(-15.0, 15.0, -15.0, 15.0, -15.0, 15.0);
	// Main
	while (!glfw.glfwWindowShouldClose(window)) {
		// Check Window Events
		glfw.glfwPollEvents();
		// Clear the screen
		gl.glClear(gl.GL_COLOR_BUFFER_BIT);
		// Draw a blue square
		gl.glBegin(gl.GL_QUADS);
		gl.glColor3d(0.0, 0.0, 1.0);
		gl.glVertex3d(-3.0, -3.0, 0.0);
		gl.glVertex3d(3.0, -3.0, 0.0);
		gl.glVertex3d(3.0, 3.0, 0.0);
		gl.glVertex3d(-3.0, 3.0, 0.0);
		gl.glEnd();
		// Draw - End
		glfw.glfwSwapBuffers(window);
		gl.glFlush();
	}
	// Deallocate GLFW Context
	glfw.glfwTerminate();
	// Exit Program
	process.exit(0);
}
// Start
main();
```
Running the code above gives:

<p align="center">
  <img width="400" src="./.github/images/simple-example.png" alt="Simple Example Result">
</p>

# Documentation
The documentation for the latest version is available [here](https://natoune.github.io/nodegl/).

# License
This package is licensed under MIT License. You can see more about it [here](./LICENSE.md)
npm package: @natoune/svelte-daisyui-toast
Description: A simple toaster component for Svelte with DaisyUI
Author: Natan Chiodi
Latest version: 1.1.1

![Header Image](/header-image.png)
<p align="center">
<img src="https://badgen.net/badge/license/MIT/422ad5" />
<img src="https://badgen.net/npm/v/@natoune/svelte-daisyui-toast" />
</p>
<p align="center">
<a href="https://natoune.github.io/svelte-daisyui-toast">Website</a> · <a href="https://npmjs.com/package/@natoune/svelte-daisyui-toast">NPM Package</a>
</p>

# Svelte DaisyUI Toast

A simple toaster component for Svelte with DaisyUI.  
Inspired by [Svelte French Toast](https://github.com/kbrgl/svelte-french-toast).

## Installation

```bash
npm install @natoune/svelte-daisyui-toast
```

```bash
pnpm install @natoune/svelte-daisyui-toast
```

```bash
yarn add @natoune/svelte-daisyui-toast
```

## Usage

Mount a `<Toaster />` at the top level of your app and use the `toast` API to display toasts.

```js
<script>
    import toast, { Toaster } from '@natoune/svelte-daisyui-toast'

    function handleClick() {
        toast.success('Hello, world!')
    }
</script>

<Toaster />
<button type="button" onclick={handleClick}>Toast</button>
```

For more usage examples, see [the website](https://natoune.github.io/svelte-daisyui-toast).

## Thanks

Thanks to the original author of Svelte French Toast and its contributors.
npm package: @natpdeveloper/permit2-sdk
Description: An sdk for interacting with permit2.
Latest version: 1.2.0

# permit2-sdk

## Local Development

### Checkout the repo
- `git clone --recurse-submodules https://github.com/Uniswap/permit2-sdk.git`

### Install dependencies
- `yarn`

### Run Unit Tests
- `yarn test`

### Run Forge tests
- `yarn build`
- `yarn interop`
- `(cd permit2 && forge build)`
- `forge test`
npm package: @natpkg/vn-local
Description: VN province, city, county, address
Author: natpkg
Latest version: 1.0.0

## Nguồn data vn-local

https://www.gso.gov.vn/phuong-phap-thong-ke/danh-muc/don-vi-hanh-chinh/

## Install

```
$ npm install @natpkg/vn-local
```

## Functions

| Function                                 | Desciption                             |
| ---------------------------------------- | -------------------------------------- |
| getProvinces()                           | Lấy danh sách các tỉnh/thành phố       |
| getProvinceByCode()                      | Lấy thông tin tỉnh/thành phố           |
| getDistricts()                           | Lấy danh sách các huyện/quận           |
| getDistrictByCode()                      | Lấy thông tin huyện/quận               |
| getWards()                               | Lấy danh sách các xã/phường            |
| getWardByCode()                          | Lấy thông tin xã/phường                |
| getDistrictsByProvinceCode(provinceCode) | Lấy danh sách huyện/ quận theo mã tỉnh |
| getWardsByDistrictCode(districtCode)     | Lấy danh sách phường/ xã theo mã huyện |
npm package: @natpkg/vue-module-acl
Description: permission, module, acl, vue, role, rule
Author: NatCoop
Latest version: 1.0.0

# vue-module-acl

## main.js

```js
import NatAcl from 'vue-module-acl'

Vue.use(NatAcl, {
  router: router, init: [
    'news.show',
    'news.post',
  ], fail: '/error'
})

const routes = [
  {
    path: '/',
    component: require('./components/home.vue'),
  },
  {
    path: '/news',
    component: require('./components/news.vue'),
    meta: { permission: { module: 'news', fail: '/error' } }
  },
  {
    path: '/error',
    component: require('./components/error.vue')
  },
]
```

## file.vue

```html
<button v-can="'news.post'">Post News</button>
```

```js
this.$canShow('news.post')
```