WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
103 commits
Select commit Hold shift + click to select a range
f91a53f
feat(setup): setup repo
ruiaraujo012 Aug 4, 2024
b3f9dd8
fix(pnpm): fix pnpm version
ruiaraujo012 Aug 4, 2024
e0cf525
fix(ci): ci test things
ruiaraujo012 Aug 4, 2024
53f0988
fix: ci
ruiaraujo012 Aug 4, 2024
b32d6f5
feat(packages): add package.json
ruiaraujo012 Aug 4, 2024
b500465
fix: test
ruiaraujo012 Aug 4, 2024
5886434
fix: test
ruiaraujo012 Aug 4, 2024
303e40b
fix: another test
ruiaraujo012 Aug 4, 2024
0fa82ea
fix: test
ruiaraujo012 Aug 4, 2024
89da782
fix: test
ruiaraujo012 Aug 4, 2024
4d7af97
feat(deps): update deps
ruiaraujo012 Aug 4, 2024
09e0f5d
fix: another one
ruiaraujo012 Aug 4, 2024
db9cc44
fix: try again with the same tag
ruiaraujo012 Aug 4, 2024
8f92c2d
fix: test
ruiaraujo012 Aug 4, 2024
6d4c43e
fix: test
ruiaraujo012 Aug 4, 2024
d0f58db
fix: test
ruiaraujo012 Aug 4, 2024
ba5a65f
fix: test
ruiaraujo012 Aug 4, 2024
b847e28
fix: finaly?
ruiaraujo012 Aug 4, 2024
5e45340
feat(version): add bum version workflow
ruiaraujo012 Aug 4, 2024
02b9177
fix: test
ruiaraujo012 Aug 4, 2024
e8c5434
bump: version 0.0.1 → 0.1.0
github-actions[bot] Aug 4, 2024
7025083
fix: test
ruiaraujo012 Aug 4, 2024
56c9048
feat(eslint): add tanstack eslint config
ruiaraujo012 Aug 4, 2024
79d4938
release: v1.0.0-beta.1
ruiaraujo012 Aug 4, 2024
c38859d
feat(eslint-react): add eslint v9 with some configs
ruiaraujo012 Aug 4, 2024
a140bd3
fix(eslint): fix missing config
ruiaraujo012 Aug 4, 2024
9cae415
release: v1.0.0-beta.2
ruiaraujo012 Aug 4, 2024
5e94f23
fix(eslint): add missing peer dep
ruiaraujo012 Aug 4, 2024
4cb3291
Merge branch 'beta' of github.com:RekStack/config into beta
ruiaraujo012 Aug 4, 2024
f0f24aa
fix(eslint): add missing peer dep
ruiaraujo012 Aug 4, 2024
a2d88b4
release: v1.0.0-beta.3
ruiaraujo012 Aug 4, 2024
04d4635
fix(eslint-react): wrong deps on package.json
ruiaraujo012 Aug 4, 2024
537e740
fix(deps): fix lock file
ruiaraujo012 Aug 4, 2024
f2f5494
release: v1.0.0-beta.4
ruiaraujo012 Aug 4, 2024
8ba8cd8
feat(prettier): add prettier config
ruiaraujo012 Aug 4, 2024
0642553
feat(prettier): add prettier config
ruiaraujo012 Aug 4, 2024
a3eb9a7
release: v1.0.0-beta.5
ruiaraujo012 Aug 4, 2024
2076ca5
fix(config): add missing config for new package
ruiaraujo012 Aug 4, 2024
05e2edd
style(eslint-react): format config file
ruiaraujo012 Aug 4, 2024
5bc5ccb
feat(prettier): add new import rules
ruiaraujo012 Aug 4, 2024
681c858
merge
ruiaraujo012 Aug 4, 2024
527976f
release: v1.0.0-beta.6
ruiaraujo012 Aug 4, 2024
1a82b4c
feat(prettier): improve prettier import order
ruiaraujo012 Aug 4, 2024
a6b44ac
release: v1.0.0-beta.7
ruiaraujo012 Aug 4, 2024
3b0631d
feat(eslint): add new rules and plugins
ruiaraujo012 Aug 4, 2024
e8f722b
release: v1.0.0-beta.8
ruiaraujo012 Aug 4, 2024
b0b095d
style: add name to some configs
ruiaraujo012 Aug 4, 2024
099e98b
feat(prettier): add pluggin to remove unused imports
ruiaraujo012 Aug 4, 2024
2732242
release: v1.0.0-beta.9
ruiaraujo012 Aug 4, 2024
26a8f16
fix(prettier): check if order of plugins matter
ruiaraujo012 Aug 4, 2024
1c5339c
release: v1.0.0-beta.10
ruiaraujo012 Aug 4, 2024
b6505e9
fix(prettier): remove extra blank line after some imports
ruiaraujo012 Aug 4, 2024
77f95ce
release: v1.0.0-beta.11
ruiaraujo012 Aug 4, 2024
529d403
fix(eslint): change no-unused-vars rule
ruiaraujo012 Aug 4, 2024
c436786
release: v1.0.0-beta.12
ruiaraujo012 Aug 4, 2024
bca5e6e
fix(eslint): apply fixup to yet unsuported plugin
ruiaraujo012 Aug 4, 2024
9cb7679
release: v1.0.0-beta.13
ruiaraujo012 Aug 4, 2024
cff84e0
fix(eslint): missing dep
ruiaraujo012 Aug 4, 2024
3a3af04
release: v1.0.0-beta.14
ruiaraujo012 Aug 4, 2024
e304272
fix(eslint): dep
ruiaraujo012 Aug 4, 2024
fa99e61
release: v1.0.0-beta.15
ruiaraujo012 Aug 4, 2024
e48a44b
feat(eslint): add two more pluggins
ruiaraujo012 Aug 6, 2024
84bcd13
release: v1.0.0-beta.16
ruiaraujo012 Aug 6, 2024
8eafc13
fix(eslint): disable prevent-abbreviations rule for props
ruiaraujo012 Aug 6, 2024
299d1ba
release: v1.0.0-beta.17
ruiaraujo012 Aug 6, 2024
575bcdc
feat(eslint): change in some rules
ruiaraujo012 Aug 6, 2024
6515688
release: v1.0.0-beta.18
ruiaraujo012 Aug 6, 2024
0cb125c
fix(eslint): fix wrong rule key
ruiaraujo012 Aug 6, 2024
277016d
release: v1.0.0-beta.19
ruiaraujo012 Aug 6, 2024
ab45062
fix(eslint): ignore routes folder for file name case
ruiaraujo012 Aug 6, 2024
3ee8bc9
release: v1.0.0-beta.20
ruiaraujo012 Aug 6, 2024
9736e22
feat(eslint): ignore routeTree.gen.ts in file name case rule
ruiaraujo012 Aug 6, 2024
fbb7f53
release: v1.0.0-beta.21
ruiaraujo012 Aug 6, 2024
dcc9789
feat(eslint): ignore routeTree.gen.ts file
ruiaraujo012 Aug 7, 2024
c9f8349
release: v1.0.0-beta.22
ruiaraujo012 Aug 7, 2024
7bd0698
fix(eslint): fix ignored files
ruiaraujo012 Aug 7, 2024
9117590
release: v1.0.0-beta.23
ruiaraujo012 Aug 7, 2024
289713a
fix(eslint): fix file name to ignore
ruiaraujo012 Aug 7, 2024
67ee5ef
release: v1.0.0-beta.24
ruiaraujo012 Aug 7, 2024
4b4195c
feat(eslint): add prop to the list of kyes to ignore in prevent-abbre…
ruiaraujo012 Aug 7, 2024
3351268
release: v1.0.0-beta.25
ruiaraujo012 Aug 7, 2024
ab68319
feat(eslint): add ref to the list of kyes to ignore in prevent-abbrev…
ruiaraujo012 Aug 7, 2024
baed755
release: v1.0.0-beta.26
ruiaraujo012 Aug 7, 2024
c8fc917
feat(eslint): add more files and folders to ignore
ruiaraujo012 Aug 7, 2024
b6b91f6
release: v1.0.0-beta.27
ruiaraujo012 Aug 7, 2024
30acfa8
feat(eslint): ignore cypress folder
ruiaraujo012 Aug 7, 2024
b9caf1d
release: v1.0.0-beta.28
ruiaraujo012 Aug 7, 2024
6a52a1c
feat(eslint): add more rules
ruiaraujo012 Aug 8, 2024
5be2e21
release: v1.0.0-beta.29
ruiaraujo012 Aug 8, 2024
07b0ae8
fix(eslint): fix plugin
ruiaraujo012 Aug 8, 2024
cc1d112
release: v1.0.0-beta.30
ruiaraujo012 Aug 8, 2024
9ba7b64
feat(eslint): disable some rules and add react-hook rules
ruiaraujo012 Aug 10, 2024
fe3213a
release: v1.0.0-beta.31
ruiaraujo012 Aug 10, 2024
8be82af
fix(eslint): fix eslint applying wrong rules
ruiaraujo012 Aug 10, 2024
5892fc3
release: v1.0.0-beta.32
ruiaraujo012 Aug 10, 2024
037d2da
feat(deps): upgrade deps
ruiaraujo012 Sep 12, 2024
e8ad91c
feat(deps): upgrade deps
ruiaraujo012 Sep 12, 2024
db8e3d4
release: v1.0.0-beta.33
ruiaraujo012 Sep 12, 2024
596f74e
feat(eslint): add new eslint tanstack query rules
ruiaraujo012 Sep 12, 2024
58c2c8f
release: v1.0.0-beta.34
ruiaraujo012 Sep 12, 2024
dec0632
feat(eslint): fix eslint config and upgrade non major deps
ruiaraujo012 Sep 18, 2024
d66504c
release: v1.0.0-beta.35
ruiaraujo012 Sep 18, 2024
1d0cefe
feat(eslint): upgrade deps to be eslint v9 compatible
ruiaraujo012 Oct 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .cz.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[tool.commitizen]
name = "cz_conventional_commits"
tag_format = "v$version"
version_scheme = "semver"
version_provider = "npm"
update_changelog_on_bump = true
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

github: [ruiaraujo012]
53 changes: 53 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: ci

on:
workflow_dispatch:
inputs:
tag:
description: override release tag
required: false
push:
branches: ['main', 'alpha', 'beta', 'next']

concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
cancel-in-progress: true

jobs:
publish:
name: Publish

# if: github.repository == 'RekStack/config'

permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests

runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Setup pnpm
uses: pnpm/action-setup@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline
- name: Publish
run: |
git config --global user.name 'Rui Araújo'
git config --global user.email '[email protected]'
npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
pnpm run cipublish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
TAG: ${{ inputs.tag }}
24 changes: 24 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v20.16.0
8 changes: 8 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
repos:
- hooks:
- id: commitizen
- id: commitizen-branch
stages:
- push
repo: https://github.com/commitizen-tools/commitizen
rev: v3.20.0
7 changes: 7 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
**/node_modules
**/dist
**/build
**/package.json
**/yarn.lock
**/package-lock.json
**/pnpm-lock.yaml
35 changes: 35 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
## v0.1.0 (2024-08-04)

### Feat

- **version**: add bum version workflow
- **deps**: update deps
- **packages**: add package.json

### Fix

- test
- finaly?
- test
- test
- test
- test
- try again with the same tag
- another one
- test
- test
- another test
- test
- test
- ci
- **ci**: ci test things

## v0.0.1 (2024-08-04)

### Feat

- **setup**: setup repo

### Fix

- **pnpm**: fix pnpm version
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
# config
# RekStack configs

- ESLint
- React
- Prettier
38 changes: 38 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "root",
"private": true,
"description": "RekStack Config",
"author": {
"name": "Rui Araujo"
},
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/RekStack/config.git"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/ruiaraujo012"
},
"type": "module",
"packageManager": "[email protected]",
"scripts": {
"build": "publint --strict",
"cipublish": "node scripts/publish.js"
},
"keywords": [
"config",
"eslint",
"react"
],
"engines": {
"node": ">=20"
},
"files": [
"packages/**"
],
"devDependencies": {
"@tanstack/config": "^0.13.4",
"publint": "^0.2.12"
}
}
46 changes: 46 additions & 0 deletions packages/eslint-react/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"name": "@rekstack/eslint-react",
"description": "RekStack ESLint react config",
"version": "1.0.0-beta.35",
"author": {
"name": "Rui Araújo"
},
"license": "MIT",
"repository": {
"directory": "packages/eslint-react",
"type": "git",
"url": "https://github.com/RekStack/config.git"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/ruiaraujo012"
},
"keywords": [
"eslint",
"react"
],
"type": "module",
"sideEffects": false,
"dependencies": {
"@eslint/compat": "^1.2.1",
"@eslint/js": "^9.13.0",
"@tanstack/eslint-plugin-query": "^5.59.7",
"eslint": "9.13.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-jsx-a11y": "^6.10.1",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-react-hooks": "^5.0.0",
"eslint-plugin-unicorn": "^56.0.0",
"eslint-plugin-unused-imports": "^4.1.4",
"globals": "^15.11.0",
"typescript-eslint": "^8.11.0"
},
"exports": {
".": {
"import": {
"default": "./src/index.js"
}
},
"./package.json": "./package.json"
}
}
133 changes: 133 additions & 0 deletions packages/eslint-react/src/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
import globals from 'globals';
import pluginJs from '@eslint/js';
import { fixupPluginRules } from '@eslint/compat';
import tseslint from 'typescript-eslint';
import pluginReact from 'eslint-plugin-react';
import pluginReactHooks from 'eslint-plugin-react-hooks';
import unusedImports from 'eslint-plugin-unused-imports';
import jsxA11y from 'eslint-plugin-jsx-a11y';
import eslintPluginUnicorn from 'eslint-plugin-unicorn';
import eslintConfigPrettier from 'eslint-config-prettier';
import pluginQuery from '@tanstack/eslint-plugin-query';

/** @type {import('eslint').Linter.Config[]} */
export default [
{ name: 'Files', files: ['**/*.{js,mjs,cjs,ts,jsx,tsx}'] },
{
name: 'Options',
languageOptions: { globals: { ...globals.browser, ...globals.node } },
settings: { react: { version: 'detect' } },
},
...pluginQuery.configs['flat/recommended'],
pluginJs.configs.recommended,
...tseslint.configs.recommended,
{
...pluginReact.configs.flat.recommended,
...pluginReact.configs.flat['jsx-runtime'],
rules: {
...pluginReact.configs.flat.recommended.rules,
...pluginReact.configs.flat['jsx-runtime'].rules,
'arrow-body-style': ['error', 'as-needed'],
'react/require-default-props': 'off',
'react/display-name': 'error',
'react/jsx-boolean-value': 'error',
'react/jsx-curly-brace-presence': [
'error',
{
props: 'never',
},
],
'react/jsx-key': 'error',
'react/jsx-no-duplicate-props': 'error',
'react/jsx-no-undef': 'error',
'react/jsx-sort-props': 'warn',
'react/jsx-uses-react': 'off',
'react/jsx-uses-vars': 'error',
'react/no-danger': 'error',
'react/no-direct-mutation-state': 'error',
'react/no-string-refs': 'error',
'react/no-unknown-property': 'error',
'react/prefer-es6-class': 'error',
'react/prefer-stateless-function': 'error',
'react/react-in-jsx-scope': 'off',
'react/self-closing-comp': 'error',
'react/sort-prop-types': 'warn',
},
},
{
...pluginReactHooks.configs.recommended,
rules: {
...pluginReactHooks.configs.recommended.rules,
// React
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',
},
},
{
plugins: {
'unused-imports': fixupPluginRules(unusedImports),
},
rules: {
// 'no-unused-vars': 'off',
// or
'@typescript-eslint/no-unused-vars': 'off',
'unused-imports/no-unused-imports': 'warn',
'unused-imports/no-unused-vars': [
'warn',
{
vars: 'all',
varsIgnorePattern: '^_',
args: 'after-used',
argsIgnorePattern: '^_',
},
],
},
},
jsxA11y.flatConfigs.recommended,
{
...eslintPluginUnicorn.configs['flat/recommended'],
rules: {
...eslintPluginUnicorn.configs['flat/recommended'].rules,
'unicorn/prevent-abbreviations': [
'error',
{
replacements: {
args: false,
prop: false,
props: false,
ref: false,
},
},
],
'unicorn/no-useless-undefined': ['off'],
'unicorn/no-null': ['off'],
'unicorn/filename-case': [
'error',
{
cases: {
kebabCase: true,
pascalCase: true,
},
ignore: [/routes\/.*\.(js|jsx|ts|tsx)$/],
},
],
},
},
{
name: 'Custom rules',
rules: {
eqeqeq: ['error', 'always', { null: 'ignore' }],
'object-shorthand': ['error', 'always'],
'no-useless-computed-key': 'error',
'@typescript-eslint/no-use-before-define': ['error'],
'prefer-template': 'error',
'sort-keys': ['warn', 'asc', { natural: true }],
},
},
// Needs to be at the end of all rules
eslintConfigPrettier,
{
name: 'Files/folders to ignore',
ignores: ['node_modules/**', 'dist/**', 'build/**', '**/generated/**', '**/routeTree.gen.ts', 'cypress/**'],
},
];
Loading