open-index/open-npm huggingface dataset:
npm package: @ithinku/eslint-config-base
Description: Base ESLint configuration for JavaScript projects (Flat Config)
Author: ithinku
Latest version: 0.1.1

# @ithinku/eslint-config-base

**Flat Config** base configuration for JavaScript projects.

This package provides the foundational ESLint rules for all `@ithinku` ESLint configurations. It targets pure JavaScript projects running in modern environments (ES2022+).

## ✨ Features

- **ESLint v9 Ready**: Fully supports the new Flat Config system.
- **Best Practices**: Includes standard rules for code quality and error prevention.
- **Unicorn**: Integrated `eslint-plugin-unicorn` for more powerful rules.
- **Prettier**: Built-in compatibility with Prettier (formatting rules disabled).
- **Import Sorting**: Auto-sort imports for cleaner code.

## 📦 Installation

```bash
npm install -D eslint @ithinku/eslint-config-base globals
```

## 🚀 Usage

Create `eslint.config.js` in your project root:

```javascript
import baseConfig from '@ithinku/eslint-config-base'
import globals from 'globals'

export default [
  ...baseConfig,
  {
    languageOptions: {
      globals: {
        ...globals.browser,
        ...globals.node
      }
    }
  }
]
```

## 📄 License

MIT
npm package: @ithinku/eslint-config-react
Description: ESLint config for React projects (Flat Config)
Author: ithinku
Latest version: 0.1.1

# @ithinku/eslint-config-react

**Flat Config** ESLint configuration for React + TypeScript projects.

Extends `@ithinku/eslint-config-ts` with React hooks and accessibility rules.

## ✨ Features

- **React 18+**: Modern React patterns (Hooks).
- **Accessibility**: Includes `jsx-a11y` rules.
- **JSX/TSX**: Optimized for JSX in TypeScript.

## 📦 Installation

```bash
npm install -D eslint @ithinku/eslint-config-react globals
```

## 🚀 Usage

Create `eslint.config.js`:

```javascript
import reactConfig from '@ithinku/eslint-config-react'

export default [
  ...reactConfig,
  {
    settings: {
      react: {
        version: 'detect'
      }
    }
  }
]
```

## 📄 License

MIT
npm package: @ithinku/eslint-config-ts
Description: ESLint config for TypeScript projects (Flat Config)
Author: ithinku
Latest version: 0.1.1

# @ithinku/eslint-config-ts

**Flat Config** ESLint configuration for TypeScript projects.

Extends `@ithinku/eslint-config-base` with TypeScript-specific rules using `typescript-eslint`.

## ✨ Features

- **TypeScript v5+**: Optimized for modern TypeScript.
- **Type-Aware Linting**: Supports rules that require type information (optional).
- **Strict Rules**: Enforces type safety (e.g., `no-explicit-any` warning).

## 📦 Installation

```bash
npm install -D eslint @ithinku/eslint-config-ts globals typescript-eslint
```

## 🚀 Usage

Create `eslint.config.js`:

```javascript
import tsConfig from '@ithinku/eslint-config-ts'

export default [
  ...tsConfig,
  {
    // Optional: Enable type-aware linting
    languageOptions: {
      parserOptions: {
        project: ['./tsconfig.json'],
        tsconfigRootDir: import.meta.dirname
      }
    }
  }
]
```

## 📄 License

MIT
npm package: @ithinku/eslint-config-vue
Description: ESLint config for Vue.js projects (Flat Config)
Author: ithinku
Latest version: 0.1.1

# @ithinku/eslint-config-vue

**Flat Config** ESLint configuration for Vue 3 + TypeScript projects.

Extends `@ithinku/eslint-config-ts` and includes `eslint-plugin-vue` recommendations.

## ✨ Features

- **Vue 3**: Supports Composition API and `<script setup>`.
- **TypeScript**: Full TypeScript support in `.vue` files.
- **Auto Ordering**: Enforces consistent order for component tags and imports.

## 📦 Installation

```bash
npm install -D eslint @ithinku/eslint-config-vue globals
```

## 🚀 Usage

Create `eslint.config.js`:

```javascript
import vueConfig from '@ithinku/eslint-config-vue'

export default [
  ...vueConfig,
  {
    // Custom overrides
    rules: {
      'vue/multi-word-component-names': 'off'
    }
  }
]
```

## 📄 License

MIT
npm package: @ithinku/expr
Description: A TypeScript expression parser library
Author: huangshan
Latest version: 0.0.2

# @ithinku/expr

A powerful and type-safe TypeScript expression parser and evaluator.

Capable of parsing mathematical expressions, handling variables, and executing safe evaluations.

## ✨ Features

- **Safe Evaluation**: Does not use `eval()` or `Function()`.
- **Variable Support**: Supports dynamic variable injection.
- **Arithmetic Operations**: `+`, `-`, `*`, `/`, unary `-`.
- **Scientific Notation**: Supports `1.2e3`, `1e-5`.
- **Error Handling**: Detailed error messages for syntax errors or runtime issues (e.g., division by zero).
- **TypeScript**: Written in strict TypeScript.

## 📦 Installation

```bash
npm install @ithinku/expr
```

## 🚀 Usage

### Simple Evaluation

```typescript
import { Expression } from '@ithinku/expr';

// Basic math
const result = Expression.evaluate('2 * (3 + 4)');
console.log(result); // 14

// Scientific notation
console.log(Expression.evaluate('1e2 * 3')); // 300
```

### Using Variables (Context)

```typescript
import { Expression } from '@ithinku/expr';

const context = { 
  x: 10, 
  y: 5,
  user: {
    age: 18
  }
};

// Access variables including nested properties
const result = Expression.evaluate('x * y + user.age', context);
console.log(result); // 10 * 5 + 18 = 68
```

### Advanced: Parser & Evaluator Separation

For better performance when evaluating the same expression multiple times with different variables.

```typescript
import { Parser, Evaluator } from '@ithinku/expr';

// 1. Parse once (Build AST)
const parser = new Parser('x * 2 + y');
const ast = parser.parse();

// 2. Create Evaluator
const evaluator = new Evaluator({ x: 10, y: 1 });

// 3. Evaluate multiple times
console.log(evaluator.evaluate(ast)); // 21

// Update variable
evaluator.setVariable('x', 20);
console.log(evaluator.evaluate(ast)); // 41
```

## ⚠️ Error Handling

```typescript
try {
  Expression.evaluate('1 / 0');
} catch (error) {
  // Error: Division by zero
}

try {
  Expression.evaluate('unknown_var * 2');
} catch (error) {
  // Error: Undefined variable: unknown_var
}
```

## 📄 License

MIT
npm package: @ithinku/prettier-config
Description: Shared Prettier configuration for iThinkU projects
Author: huangshan
Latest version: 0.0.2

# @ithinku/prettier-config

Shared Prettier configuration for iThinkU projects.

## Install

```bash
pnpm add -D @ithinku/prettier-config
```

## Usage

Package.json:

```json
{
  "prettier": "@ithinku/prettier-config"
}
```

Or a config file:

```js
// .prettierrc.cjs
module.exports = require('@ithinku/prettier-config')
```

## Customize

Override in your local config as needed:

```js
// .prettierrc.cjs
module.exports = {
  ...require('@ithinku/prettier-config'),
  printWidth: 100
}
```
npm package: @ithinku/shared
Description: Shared utilities for iThinkU projects
Author: huangshan
Latest version: 0.0.2

# @ithinku/shared

高性能、零依赖、类型安全的 TypeScript 通用工具函数库。

旨在提供日常开发中最常用的数组、对象、类型判断和时间处理函数，所有函数均支持 Tree-shaking。

## ✨ 特性

- **轻量级**: 零外部依赖，打包体积极小。
- **Type-Safe**: 完备的 TypeScript 类型定义。
- **Immutable**: 数组操作默认不修改原数组（如 `sort`）。
- **Modular**: 支持按需导入。

## 📦 安装

```bash
npm install @ithinku/shared
# or
pnpm add @ithinku/shared
```

## 📚 API 文档

### 类型判断 (`Type`)

提供比 `typeof` 更精准的类型判断。

```typescript
import { isArray, isObject, isEmpty, isType } from '@ithinku/shared'

isArray([]) // true
isObject({}) // true
isObject(null) // false (注意：原生 typeof null === 'object')

// 智能判空 (支持 Array, Object, Map, Set, String)
isEmpty([]) // true
isEmpty({}) // true
isEmpty('') // true
isEmpty(0) // false (0 是有效值)
isEmpty(undefined) // true

// 获取真实类型字符串
isType(new Date()) // 'Date'
isType(/regex/) // 'RegExp'
```

### 数组工具 (`Array`)

**注意**：所有修改操作均返回新数组，不影响原数组。

```typescript
import { sort, unique, avg, max, min, mode, median } from '@ithinku/shared'

const arr = [3, 1, 2, 2]

// 排序 (返回新副本)
sort(arr) // [1, 2, 2, 3]
console.log(arr) // [3, 1, 2, 2] (原数组未变)

// 去重
unique(arr) // [3, 1, 2]

// 统计计算
avg([1, 2, 3]) // 2
max([1, 5, 2]) // 5 (空数组返回 undefined)
min([1, 5, 2]) // 1 (空数组返回 undefined)

// 众数
mode([1, 2, 2, 3]) // [2]

// 中位数
median([1, 3, 2]) // 2
```

### 时间处理 (`Time`)

轻量级的日期格式化工具。

```typescript
import { format } from '@ithinku/shared'

const date = new Date('2024-01-01 13:00:00')

// 默认格式: YYYY-MM-DD HH:mm:ss
format(date) // "2024-01-01 13:00:00"

// 自定义格式 (支持 YYYY, MM, DD, HH, mm, ss, SSS)
format(date, { format: 'YYYY/MM/DD' }) // "2024/01/01"
```

### 转换工具

```typescript
import { objToArr, arrToObj } from '@ithinku/shared'

const obj = { a: 1, b: 2 }
objToArr(obj) // [['a', 1], ['b', 2]]

const entries = [['a', 1], ['b', 2]]
arrToObj(entries) // { a: 1, b: 2 }
```

## 📄 License

MIT
npm package: @ithinku/tsconfig
Description: custom tsconfig for huangshan
Author: huangshan
Latest version: 0.0.7

# @ithinku/tsconfig

Shared [TypeScript configuration](https://www.typescriptlang.org/docs/handbook/tsconfig-json.html) bases for iThinkU projects.

Provides a set of composable `tsconfig.json` files to ensure consistent compiler options across the monorepo.

## 📦 Available Configs

| Config         | Extends     | Purpose                                                                  |
| -------------- | ----------- | ------------------------------------------------------------------------ |
| `base.json`    | -           | The minimal base configuration (ES2022, Strict).                         |
| `strict.json`  | `base.json` | Enables maximum strictness (noImplicitAny, etc.).                        |
| `node.json`    | `base.json` | Optimized for Node.js environments.                                      |
| `dom.json`     | `base.json` | Optimized for Browser environments (DOM lib).                            |
| `bundler.json` | `base.json` | Optimized for Bundlers (Vite/Rollup) with `moduleResolution: "Bundler"`. |

> Note: All specific configs also have a `-strict` variant (e.g., `bundler-strict.json`) which extends `strict.json`.

## 🚀 Usage

Install the package:

```bash
npm install -D @ithinku/tsconfig
```

Extend it in your `tsconfig.json`:

```json
{
  "extends": "@ithinku/tsconfig/bundler-strict",
  "compilerOptions": {
    "outDir": "dist",
    "rootDir": "src"
  },
  "include": ["src"]
}
```

## 📄 License

MIT
npm package: @itho/dsa
Description: Data Structures and Algorithms
Author: Ieuan Thomas
Latest version: 0.1.0

# dsa
## Data Structures and Algorithms

[![CircleCI](https://img.shields.io/circleci/build/gh/itho/dsa/master.svg)](https://circleci.com/gh/itho/dsa)
[![Codecov Coverage](https://img.shields.io/codecov/c/github/itho/dsa/master.svg)](https://codecov.io/gh/itho/dsa/)