Skip to content

Commit a2367e5

Browse files
committed
feat: initial commit
0 parents  commit a2367e5

10 files changed

Lines changed: 7382 additions & 0 deletions

File tree

.ddev/config.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: eslint-config-typescript
2+
type: php
3+
docroot: ""
4+
php_version: "8.5"
5+
webserver_type: apache-fpm
6+
xdebug_enabled: false
7+
additional_hostnames: []
8+
additional_fqdns: []
9+
database:
10+
type: mariadb
11+
version: "10.11"
12+
use_dns_when_possible: true
13+
composer_version: "2"
14+
web_environment: []
15+
corepack_enable: false
16+
nodejs_version: "24"

.editorconfig

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
indent_style = space
7+
indent_size = 4
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true
10+
11+
[*.json]
12+
indent_style = tab
13+
14+
[*.mjs]
15+
indent_size = 2
16+
17+
[*.yml]
18+
indent_size = 2

.github/workflows/release.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- release/*
8+
9+
permissions:
10+
contents: write
11+
id-token: write
12+
issues: write
13+
pull-requests: write
14+
15+
jobs:
16+
release:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v6
20+
with:
21+
fetch-depth: 0
22+
- uses: actions/setup-node@v6
23+
with:
24+
node-version: "lts/*"
25+
cache: "npm"
26+
registry-url: "https://registry.npmjs.org"
27+
- run: npm ci
28+
- run: npm audit signatures
29+
- name: Release
30+
env:
31+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32+
run: npx semantic-release

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/node_modules/

.releaserc.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
branches:
2+
- main
3+
- name: release/*
4+
prerelease: true

LICENSE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 move elevator GmbH
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# @move-elevator/eslint-config-typescript
2+
3+
A shareable Eslint configuration for TypeScript projects.
4+
5+
## Installation
6+
7+
```bash
8+
npm i -D @move-elevator/eslint-config-typescript
9+
```
10+
11+
### Peer Dependencies
12+
13+
This package requires the following peer dependencies:
14+
15+
```bash
16+
npm i -D eslint eslint-plugin-perfectionist eslint-plugin-prefer-arrow-functions typescript-eslint
17+
```
18+
19+
## Usage
20+
21+
Create an Eslint config file like `eslint.config.mjs` in your project root and extend this configuration:
22+
23+
```javascript
24+
import config from '@move-elevator/eslint-config-typescript'
25+
26+
export default [
27+
...config,
28+
{
29+
// your custom rules
30+
}
31+
]
32+
```
33+
34+
## What's Included
35+
36+
This configuration extends:
37+
38+
- `@eslint/js` recommended rules
39+
- `typescript-eslint` recommended rules
40+
- `eslint-plugin-perfectionist` alphabetical sorting rules
41+
42+
Additional rules:
43+
44+
- `no-undef`: error
45+
- `prefer-arrow-functions/prefer-arrow-functions`: error
46+
- `quotes`: single quotes required
47+
- `semi`: no semicolons
48+
49+
## License
50+
51+
[MIT](LICENSE.md)

index.mjs

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
import js from '@eslint/js'
2+
import perfectionist from 'eslint-plugin-perfectionist'
3+
import preferArrowFunctions from 'eslint-plugin-prefer-arrow-functions'
4+
import globals from 'globals'
5+
import ts from 'typescript-eslint'
6+
7+
export default ts.config({
8+
extends: [
9+
js.configs.recommended,
10+
ts.configs.recommended,
11+
perfectionist.configs["recommended-alphabetical"]
12+
],
13+
files: ['*.{js,mjs,ts}', '**/*.{js,mjs,ts}'],
14+
languageOptions: {
15+
globals: {
16+
...globals.browser,
17+
...globals.node,
18+
NodeListOf: 'readonly',
19+
},
20+
},
21+
plugins: {
22+
'prefer-arrow-functions': preferArrowFunctions
23+
},
24+
rules: {
25+
'no-undef': 'error',
26+
'prefer-arrow-functions/prefer-arrow-functions': 'error',
27+
quotes: ['error', 'single'],
28+
semi: ['error', 'never'],
29+
}
30+
})

0 commit comments

Comments
 (0)