-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: add new linter * chore: format files * chore: add linted files * fix: copy readme & package.json & license to dist after build otherwise, we get MissingPackageJSON error when installing upstash/redis in our CI tests https://github.com/upstash/redis-js/actions/runs/10091669210/job/27903832137 installing with npm instead of bun solves the issue but we get another error when running: https://github.com/upstash/redis-js/actions/runs/10091973099/job/27904892427 * fix: remove flaky tests --------- Co-authored-by: CahidArda <[email protected]>
- Loading branch information
1 parent
42ebc46
commit 26a3a66
Showing
240 changed files
with
1,252 additions
and
1,010 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,44 @@ | ||
{ | ||
"env": { | ||
"es2024": true | ||
}, | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:unicorn/recommended", | ||
"plugin:@typescript-eslint/recommended" | ||
], | ||
"plugins": ["@typescript-eslint", "unicorn"], | ||
"parserOptions": { | ||
"project": "./tsconfig.json" | ||
}, | ||
"ignorePatterns": ["*.config.*", "examples", "dist"], | ||
"rules": { | ||
"no-console": ["error", { "allow": ["warn", "error"] }], | ||
"@typescript-eslint/no-magic-numbers": "off", | ||
"@typescript-eslint/unbound-method": "off", | ||
"@typescript-eslint/prefer-as-const": "error", | ||
"@typescript-eslint/consistent-type-imports": "error", | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"@typescript-eslint/restrict-template-expressions": "off", | ||
"@typescript-eslint/consistent-type-definitions": ["error", "type"], | ||
"@typescript-eslint/no-unused-vars": [ | ||
"error", | ||
{ "varsIgnorePattern": "^_", "argsIgnorePattern": "^_" } | ||
], | ||
"@typescript-eslint/prefer-ts-expect-error": "off", | ||
"@typescript-eslint/no-misused-promises": [ | ||
"error", | ||
{ | ||
"checksVoidReturn": false | ||
} | ||
], | ||
"unicorn/prevent-abbreviations": "off", | ||
"no-implicit-coercion": ["error", { "boolean": true }], | ||
"no-extra-boolean-cast": ["error", { "enforceForLogicalOperands": true }], | ||
"no-unneeded-ternary": ["error", { "defaultAssignment": true }], | ||
"unicorn/no-array-reduce": ["off"], | ||
"unicorn/no-nested-ternary": "off", | ||
"unicorn/no-null": "off", | ||
"unicorn/filename-case": "off" | ||
} | ||
} |
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 |
---|---|---|
@@ -1,21 +1,175 @@ | ||
.vscode/ | ||
npm/ | ||
node_modules/ | ||
# Based on https://raw.githubusercontent.com/github/gitignore/main/Node.gitignore | ||
|
||
# Logs | ||
|
||
logs | ||
_.log | ||
npm-debug.log_ | ||
yarn-debug.log* | ||
yarn-error.log* | ||
lerna-debug.log* | ||
.pnpm-debug.log* | ||
|
||
# Caches | ||
|
||
.cache | ||
|
||
# Diagnostic reports (https://nodejs.org/api/report.html) | ||
|
||
report.[0-9]_.[0-9]_.[0-9]_.[0-9]_.json | ||
|
||
# Runtime data | ||
|
||
pids | ||
_.pid | ||
_.seed | ||
*.pid.lock | ||
|
||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
|
||
lib-cov | ||
|
||
# Coverage directory used by tools like istanbul | ||
|
||
coverage | ||
.env* | ||
!.env.example | ||
.pnpm-debug.log | ||
dist/ | ||
.idea/ | ||
.next/ | ||
*.lcov | ||
|
||
# nyc test coverage | ||
|
||
.nyc_output | ||
|
||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) | ||
|
||
.grunt | ||
|
||
# Bower dependency directory (https://bower.io/) | ||
|
||
bower_components | ||
|
||
# node-waf configuration | ||
|
||
.lock-wscript | ||
|
||
# Compiled binary addons (https://nodejs.org/api/addons.html) | ||
|
||
build/Release | ||
|
||
# Dependency directories | ||
|
||
node_modules/ | ||
jspm_packages/ | ||
|
||
# Snowpack dependency directory (https://snowpack.dev/) | ||
|
||
web_modules/ | ||
|
||
# TypeScript cache | ||
|
||
*.tsbuildinfo | ||
|
||
# Optional npm cache directory | ||
|
||
.npm | ||
|
||
# Optional eslint cache | ||
|
||
.eslintcache | ||
|
||
# Optional stylelint cache | ||
|
||
.stylelintcache | ||
|
||
# Microbundle cache | ||
|
||
.rpt2_cache/ | ||
.rts2_cache_cjs/ | ||
.rts2_cache_es/ | ||
.rts2_cache_umd/ | ||
|
||
# Optional REPL history | ||
|
||
.node_repl_history | ||
|
||
# Output of 'npm pack' | ||
|
||
*.tgz | ||
|
||
# Yarn Integrity file | ||
|
||
.yarn-integrity | ||
|
||
# dotenv environment variable files | ||
|
||
.env | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
.env.local | ||
|
||
# parcel-bundler cache (https://parceljs.org/) | ||
|
||
.parcel-cache | ||
|
||
# Next.js build output | ||
|
||
.next | ||
out | ||
|
||
# Nuxt.js build / generate output | ||
|
||
.nuxt | ||
dist | ||
|
||
# Gatsby files | ||
|
||
# Comment in the public line in if your project uses Gatsby and not Next.js | ||
|
||
# https://nextjs.org/blog/next-9-1#public-directory-support | ||
|
||
# public | ||
|
||
# vuepress build output | ||
|
||
.vuepress/dist | ||
|
||
# vuepress v2.x temp and cache directory | ||
|
||
.temp | ||
|
||
# Docusaurus cache and generated files | ||
|
||
.docusaurus | ||
|
||
# Serverless directories | ||
|
||
.serverless/ | ||
|
||
# FuseBox cache | ||
|
||
.fusebox/ | ||
|
||
# DynamoDB Local files | ||
|
||
.dynamodb/ | ||
|
||
# TernJS port file | ||
|
||
.tern-port | ||
|
||
# Stores VSCode versions used for testing VSCode extensions | ||
|
||
examples/**/yarn.lock | ||
examples/**/package-lock.json | ||
examples/**/pnpm-lock.yaml | ||
.vscode-test | ||
|
||
# yarn v2 | ||
|
||
.yarn/cache | ||
.yarn/unplugged | ||
.yarn/build-state.yml | ||
.yarn/install-state.gz | ||
.pnp.* | ||
|
||
# IntelliJ based IDEs | ||
.idea | ||
|
||
# Local Netlify folder | ||
.netlify | ||
x/ | ||
# Finder (MacOS) folder config | ||
.DS_Store |
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 @@ | ||
bun --no -- commitlint --edit "" |
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 |
---|---|---|
@@ -1,4 +1,2 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
bun run fmt && bun 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 @@ | ||
bun run build |
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 @@ | ||
**/examples |
This file was deleted.
Oops, something went wrong.
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": ["dbaeumer.vscode-eslint", "esbenp.prettier-vscode"] | ||
} |
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,20 @@ | ||
{ | ||
"editor.formatOnSave": true, | ||
"git.autofetch": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll": "explicit" | ||
}, | ||
"[json]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"[javascript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"[jsonc]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
} |
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
This file was deleted.
Oops, something went wrong.
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,46 @@ | ||
// build: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm) | ||
// ci: Changes to our CI configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs) | ||
// docs: Documentation only changes | ||
// feat: A new feature | ||
// fix: A bug fix | ||
// perf: A code change that improves performance | ||
// refactor: A code change that neither fixes a bug nor adds a feature | ||
// style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc) | ||
// test: Adding missing tests or correcting existing tests | ||
|
||
module.exports = { | ||
extends: ["@commitlint/config-conventional"], | ||
rules: { | ||
"body-leading-blank": [1, "always"], | ||
"body-max-line-length": [2, "always", 100], | ||
"footer-leading-blank": [1, "always"], | ||
"footer-max-line-length": [2, "always", 100], | ||
"header-max-length": [2, "always", 100], | ||
"scope-case": [2, "always", "lower-case"], | ||
"subject-case": [2, "never", ["sentence-case", "start-case", "pascal-case", "upper-case"]], | ||
"subject-empty": [2, "never"], | ||
"subject-full-stop": [2, "never", "."], | ||
"type-case": [2, "always", "lower-case"], | ||
"type-empty": [2, "never"], | ||
"type-enum": [ | ||
2, | ||
"always", | ||
[ | ||
"build", | ||
"chore", | ||
"ci", | ||
"docs", | ||
"feat", | ||
"fix", | ||
"perf", | ||
"refactor", | ||
"revert", | ||
"style", | ||
"test", | ||
"translation", | ||
"security", | ||
"changeset", | ||
], | ||
], | ||
}, | ||
}; |
Oops, something went wrong.