-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 68d93a5
Showing
30 changed files
with
11,119 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": ["config:base", "schedule:monthly", "group:allNonMajor"], | ||
"rangeStrategy": "bump", | ||
"packageRules": [{ "depTypeList": ["peerDependencies"], "enabled": false }] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
|
||
name: Release Full | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
version: | ||
type: choice | ||
description: "Release Version Type" | ||
required: true | ||
default: "patch" | ||
options: | ||
- major | ||
- premajor | ||
- minor | ||
- preminor | ||
- patch | ||
- prepatch | ||
- prerelease | ||
|
||
tag: | ||
type: choice | ||
description: "Release Npm Tag" | ||
required: true | ||
default: "latest" | ||
options: | ||
- canary | ||
- nightly | ||
- latest | ||
- beta | ||
- alpha | ||
|
||
dry_run: | ||
type: boolean | ||
description: "DryRun release" | ||
required: true | ||
default: false | ||
|
||
permissions: | ||
# To publish packages with provenance | ||
id-token: write | ||
|
||
jobs: | ||
release: | ||
name: Release | ||
permissions: | ||
contents: write | ||
# To publish packages with provenance | ||
id-token: write | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Pnpm | ||
run: corepack enable | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
cache: "pnpm" | ||
|
||
- name: Install Dependencies | ||
run: pnpm install | ||
|
||
- name: Run Test | ||
run: pnpm run test | ||
|
||
- name: Try release to npm | ||
run: pnpm run release | ||
env: | ||
DRY_RUN: ${{ inputs.dry_run }} | ||
TAG: ${{ inputs.tag }} | ||
VERSION: ${{ inputs.version }} | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: Test | ||
|
||
# Controls when the action will run. | ||
on: | ||
# Triggers the workflow on pull request events but only for the main branch | ||
pull_request: | ||
branches: [main] | ||
push: | ||
branches: [main] | ||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | ||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
|
||
# Steps represent a sequence of tasks that will be executed as part of the job | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Pnpm | ||
run: corepack enable | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
cache: "pnpm" | ||
|
||
- name: Install Dependencies | ||
run: pnpm install | ||
|
||
- name: Run Test | ||
run: pnpm run test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Local | ||
.DS_Store | ||
*.local | ||
*.log* | ||
|
||
# Dist | ||
node_modules | ||
dist/ | ||
test-results | ||
|
||
# Test | ||
test/js/ | ||
|
||
# IDE | ||
.vscode/* | ||
!.vscode/settings.json | ||
!.vscode/extensions.json | ||
.idea | ||
*.tsbuildinfo | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"recommendations": ["biomejs.biome"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"search.useIgnoreFiles": true, | ||
"[json]": { | ||
"editor.defaultFormatter": "biomejs.biome" | ||
}, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "biomejs.biome" | ||
}, | ||
"[javascript]": { | ||
"editor.defaultFormatter": "biomejs.biome" | ||
}, | ||
"[javascriptreact]": { | ||
"editor.defaultFormatter": "biomejs.biome" | ||
}, | ||
"[css]": { | ||
"editor.defaultFormatter": "biomejs.biome" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# @rspack/lite-tapable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
MIT License | ||
|
||
Copyright (c) 2022-present Bytedance, Inc. and its affiliates. | ||
|
||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<picture> | ||
<source media="(prefers-color-scheme: dark)" srcset="https://assets.rspack.dev/rspack/rspack-banner-plain-dark.png"> | ||
<img alt="Rspack Banner" src="https://assets.rspack.dev/rspack/rspack-banner-plain-light.png"> | ||
</picture> | ||
|
||
# @rspack/lite-tapable | ||
|
||
Lite weight tapable for Rspack. | ||
|
||
## Documentation | ||
|
||
See <https://rspack.dev> for details. | ||
|
||
## License | ||
|
||
Rspack is [MIT licensed](https://github.com/web-infra-dev/rspack/blob/main/LICENSE). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json", | ||
"organizeImports": { | ||
"enabled": true | ||
}, | ||
"vcs": { | ||
"enabled": true, | ||
"defaultBranch": "main", | ||
"clientKind": "git", | ||
"useIgnoreFile": true | ||
}, | ||
"formatter": { | ||
"indentStyle": "space", | ||
"ignore": ["./test/**/*"] | ||
}, | ||
"javascript": { | ||
"formatter": { | ||
"quoteStyle": "single" | ||
} | ||
}, | ||
"css": { | ||
"formatter": { | ||
"enabled": true | ||
} | ||
}, | ||
"linter": { | ||
"enabled": true, | ||
"rules": { | ||
"recommended": true, | ||
"correctness": { | ||
"noVoidTypeReturn": "off" | ||
}, | ||
"complexity": { | ||
"noBannedTypes": "off" | ||
} | ||
}, | ||
"ignore": ["./test/**/*", "./scripts/**/*"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/** @type {import('ts-jest/dist/types').JestConfigWithTsJest} */ | ||
const config = { | ||
preset: 'ts-jest', | ||
testEnvironment: './scripts/patch-node-env.cjs', | ||
testTimeout: process.env.CI ? 200000 : 30000, | ||
testMatch: ['<rootDir>/test/**/*.test.ts', '<rootDir>/test/**/*.test.js'], | ||
watchPathIgnorePatterns: ['<rootDir>/test/.*/dist'], | ||
extensionsToTreatAsEsm: ['.mts'], | ||
}; | ||
|
||
module.exports = config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{ | ||
"name": "@rspack/lite-tapable", | ||
"version": "1.0.0-beta.3", | ||
"repository": "https://github.com/rspack-contrib/rspack-lite-tapable", | ||
"license": "MIT", | ||
"description": "Lite weight tapable for Rspack", | ||
"main": "./dist/index.js", | ||
"types": "./dist/index.d.ts", | ||
"scripts": { | ||
"build": "tsc -b ./tsconfig.build.json", | ||
"dev": "tsc -b -w", | ||
"lint": "biome check .", | ||
"lint:write": "biome check . --write", | ||
"prepare": "simple-git-hooks && npm run build", | ||
"test": "jest --colors", | ||
"release": "node ./scripts/release.mjs" | ||
}, | ||
"files": ["dist"], | ||
"simple-git-hooks": { | ||
"pre-commit": "npx nano-staged" | ||
}, | ||
"nano-staged": { | ||
"*.{js,jsx,ts,tsx,mjs,cjs}": [ | ||
"biome check --write --no-errors-on-unmatched" | ||
] | ||
}, | ||
"devDependencies": { | ||
"@biomejs/biome": "^1.8.3", | ||
"@rspack/core": "1.0.0-beta.3", | ||
"@rspack/test-tools": "1.0.0-beta.3", | ||
"@types/node": "^20.14.13", | ||
"@types/jest": "29.5.12", | ||
"cross-env": "^7.0.3", | ||
"execa": "9.3.0", | ||
"fs-extra": "11.2.0", | ||
"jest": "29.7.0", | ||
"jest-cli": "29.7.0", | ||
"jest-environment-node": "29.7.0", | ||
"nano-staged": "^0.8.0", | ||
"semver": "7.6.3", | ||
"simple-git-hooks": "^2.11.1", | ||
"ts-jest": "29.1.2", | ||
"typescript": "5.0.2" | ||
}, | ||
"packageManager": "[email protected]", | ||
"publishConfig": { | ||
"access": "public", | ||
"registry": "https://registry.npmjs.org/", | ||
"provenance": true | ||
}, | ||
"engines": { | ||
"node": ">=16.0.0" | ||
} | ||
} |
Oops, something went wrong.