open-index/open-npm huggingface dataset:
npm package: @taiyuuki/esbuild-plugin-import-glob
Description: A esbuild plugin which allows to import multiple files using the glob syntax.
Author: Thomas Schaaf
Latest version: 0.1.7

# esbuild-plugin-import-glob

A esbuild plugin which allows to import multiple files using the glob syntax.

Forked from [`esbuild-plugin-import-glob`](https://github.com/thomaschaaf/esbuild-plugin-import-glob)

Change in this fork: Prefix the path of the import to declare types.

## Usage

Install this plugin in your project:

```sh
npm install --save-dev @taiyuuki/esbuild-plugin-import-glob
```

Add this plugin to your esbuild build script:

```diff
+import importGlobPlugin from '@taiyuuki/esbuild-plugin-import-glob'
 ...
 esbuild.build({
   ...
   plugins: [
+    importGlobPlugin(),
   ],
 })
```

Import

```ts
// @ts-ignore
import migrationsArray from './migrations/**/*'

migrationsArray[0].default
```

```ts
// @ts-ignore
import * as migrations from './migrations/**/*'

const { default: migrationsArray, filenames } = migrations;
```

### Prefix

If you don't want to use `@ts-ignore`, you can type declare the module, but ambient module declaration cannot specify relative module name.

```ts
// Error: Ambient module declaration cannot specify relative module name. ts(2436)
declare module './migrations/*' {
    
}
```

 You can add a prefix to avoid it.

```ts
import importGlobPlugin from '@taiyuuki/esbuild-plugin-import-glob'
import esbuild from 'esbuild'

esbuild.build({
    plugins: [
        importGlobPlugin({
            prefix: 'glob'
        })
    ]
})
```

Import with the prefix.

```ts
// Note the colon after prefix
import migrationsArray from 'glob:./migrations/**/*'

migrationsArray[0].default
```

Example of module declaration.

```ts
// types.d.ts
declare module 'glob:./migrations/*' {
    interface Example { /*  */ }
    const examples: { default: Example }[]
    export default examples
}
```
npm package: @taiyuuki/eslint-config
Description: ```bash pnpm i @taiyuuki/eslint-config -D ```
Author: taiyuuki
Latest version: 1.6.6

# Usage

```bash
pnpm i @taiyuuki/eslint-config -D
```

```js
// eslint.config.mjs
import tyk_config from '@taiyuuki/eslint-config'

export default tyk_config({
    indent:   2, // default 4
    ts:       true, // default false
    vue:      true, // default false
    markdown: false, // default true
    json:     false, // default true
    ignores:  ['scripts/**'],
    rules:    {
        
        // custom rules
        curly: ['error'],
    },
})
```
npm package: @taiyuuki/eslint-config-ts
Description: ts eslint config by taiyuuki
Author: taiyuuki
Latest version: 0.0.9

### Typescript eslint config

install:

```shell
npm i @taiyuuki/eslint-config-ts -D

yarn add @taiyuuki/eslint-config-ts -D

pnpm install @taiyuuki/eslint-config-ts -D
```

VS Code `settings.json`:

```json
{
    "eslint.format.enable": true,
    "editor.codeActionsOnSave": {
        "source.fixAll": true,
        "source.fixAll.eslint": true
    }
}
```

`.eslintrc.js`:

```js
module.exports = {
  root: true,
  extends: ['@taiyuuki/eslint-config-ts'],
}
```
npm package: @taiyuuki/eslint-config-vue-unimport
Description: vue eslint config with unplugin-auto-import
Author: taiyuuki
Latest version: 0.0.9

### vue eslint config with unplugin-auto-import

install:

```shell
npm i @taiyuuki/eslint-config-vue-unimport -D

yarn add @taiyuuki/eslint-config-vue-unimport -D

pnpm install @taiyuuki/eslint-config-vue-unimport -D
```

VS Code `settings.json`:

```json
{
    "eslint.format.enable": true,
    "editor.codeActionsOnSave": {
        "source.fixAll": true,
        "source.fixAll.eslint": true
    }
}
```

`.eslintrc.js`:

```js
module.exports = {
  root: true,
  extends: ['@taiyuuki/eslint-config-vue-unimport'],
}
```
npm package: @taiyuuki/unocss-preset
Description: opiniated unocss preset
Author: taiyuuki
Latest version: 0.0.4

## @taiyuuki/unocss-preset

### Install

```bash
npm i @taiyuuki/unocss-preset -D
```

```js
// uno.config.js
import {
  defineConfig,
  presetUno,
  presetAttributify,
  presetIcons,
} from 'unocss'
import { presetTaiyuuki } from '@taiyuuki/unocss-preset'

export default defineConfig({
  presets: [
    presetAttributify({}),
    presetUno(),
    presetIcons(),
    presetTaiyuuki(),
  ]
})
```

### rules

| Prefix        | CSS                        |
| ------------- | -------------------------- |
| border        | border                     |
| border-width  | border-width               |
| border-color  | border-color               |
| border-radius | border-radius              |
| shadow        | box-shadow                 |
| w             | width                      |
| w-min         | min-width                  |
| h             | height                     |
| h-min         | min-height                 |
| m             | margin                     |
| m-x           | margin-right margin-left   |
| m-y           | margin-top margin-bottom   |
| m-t           | margin-top                 |
| m-r           | margin-right               |
| m-b           | margin-bottom              |
| m-l           | margin-left                |
| p             | padding                    |
| p-x           | padding-right padding-left |
| p-y           | padding-top padding-bottom |
| p-t           | padding-top                |
| p-r           | padding-right              |
| p-b           | padding-bottom             |
| p-l           | padding-left               |
| pst           | position                   |
| pst-t         | top                        |
| pst-r         | right                      |
| pst-b         | bottom                     |
| pst-l         | left                       |
| z-index       | z-index                    |
| flex          | flex                       |
| flex-row      | flex-direction             |
| row           | flex-direction             |
| flex-column   | flex-direction             |
| column        | flex-direction             |
| text-color    | color                      |
| text-weight   | font-weight                |
| text-align    | text-align                 |
| text-vertical | vertical-align             |
| bg            | background                 |
| bg-repeat     | background-repeat          |
| bg-position   | background-position        |
| bg-size       | background-size            |
| bg-color      | background-color           |
| display       | display                    |
| gap           | gap                        |
| icon-color    | fill                       |
| overflow      | overflow                   |
| overflow-x    | overflow-x                 |
| overflow-y    | overflow-y                 |
| opacity       | opacity                    |
| filter        | filter                     |
| obj-fit       | object-fit                 |
| obj-contain   | object-contain             |
npm package: @taiyuuki/vec-js
Description: A JavaScript library for working with vectors.
Author: taiyuuki
Latest version: 0.0.4

### vec-js

A JavaScript library for working with vectors.

## Usage

```bash
npm install @taiyuuki/vec-js
```

```javascript
import { vec2, vec3, vec4 } from '@taiyuuki/vec-js'

const v3 = vec3(1, 2, 3)

console.log(v3.x) // 1
console.log(v3.y) // 2
console.log(v3.z) // 3
console.log(v3.r) // 1
console.log(v3.g) // 2
console.log(v3.b) // 3
console.log(v3.xx) // {x: 1, y: 1}
console.log(v3.xy) // {x: 1, y: 2}
console.log(v3.rgb) // {x: 1, y: 2, z: 3}

```