Skip to content

Commit c5717af

Browse files
authored
Merge pull request #44 from Alexoner03/aortiz_tieredprice_typescript
Aortiz tieredprice typescript
2 parents 7d1f566 + dfcb515 commit c5717af

File tree

15 files changed

+5403
-0
lines changed

15 files changed

+5403
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
module.exports = {
2+
parser: "@typescript-eslint/parser",
3+
extends: [
4+
"plugin:@typescript-eslint/recommended",
5+
"plugin:prettier/recommended",
6+
],
7+
plugins: ["simple-import-sort", "import"],
8+
parserOptions: {
9+
ecmaVersion: 12,
10+
sourceType: "module",
11+
},
12+
rules: {
13+
"simple-import-sort/imports": "error",
14+
"simple-import-sort/exports": "error",
15+
"import/first": "error",
16+
"import/newline-after-import": "error",
17+
"import/no-duplicates": "error",
18+
},
19+
};
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: CI
2+
3+
on: push
4+
5+
jobs:
6+
unit:
7+
runs-on: ubuntu-latest
8+
name: 🚀 Lint and test
9+
timeout-minutes: 5
10+
steps:
11+
- name: 👍 Checkout
12+
uses: actions/checkout@v2
13+
14+
- name: 📦 Cache node modules
15+
uses: actions/cache@v2
16+
env:
17+
cache-name: cache-node-modules
18+
with:
19+
path: ~/.npm
20+
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
21+
restore-keys: |
22+
${{ runner.os }}-build-${{ env.cache-name }}-
23+
${{ runner.os }}-build-
24+
${{ runner.os }}-
25+
26+
- name: 📥 Install dependencies
27+
run: npm install
28+
29+
- name: 💅 Lint code style
30+
run: npm run lint
31+
32+
- name: ✅ Run tests
33+
run: npm run test
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules/
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) 2022 Codely Enseña y Entretiene SL
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.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# 🔷🌱 TypeScript Basic Skeleton
2+
3+
Template intended to serve as a starting point if you want to bootstrap a project in TypeScript.
4+
5+
The purpose of this repository is to leave it with the bare minimum dependencies and tools needed to run TypeScript snippets or start you project without any opinionated decision already made.
6+
7+
## Features
8+
9+
- [TypeScript](https://www.typescriptlang.org/) (v4)
10+
- [Prettier](https://prettier.io/)
11+
- [ESLint](https://eslint.org/) with:
12+
- [Simple Import Sort](https://github.com/lydell/eslint-plugin-simple-import-sort/)
13+
- [Import plugin](https://github.com/benmosher/eslint-plugin-import/)
14+
- And a few other ES2015+ related rules
15+
- [Jest](https://jestjs.io) with [DOM Testing Library](https://testing-library.com/docs/dom-testing-library/intro)
16+
- [GitHub Action workflows](https://github.com/features/actions) set up to run tests and linting on push
17+
- [SWC](https://swc.rs/): Execute your tests in less than 200ms
18+
19+
## Running the app
20+
21+
- Install the dependencies: `npm install`
22+
- Execute the tests: `npm run test`
23+
- Check linter errors: `npm run lint`
24+
- Fix linter errors: `npm run lint:fix`
25+
26+
## Related skeleton templates
27+
28+
Opinionated TypeScript skeletons ready for different purposes:
29+
30+
- [🔷🕸️ TypeScript Web Skeleton](https://github.com/CodelyTV/typescript-web-skeleton)
31+
- [🔷🌍 TypeScript API Skeleton](https://github.com/CodelyTV/typescript-api-skeleton)
32+
- [🔷✨ TypeScript DDD Skeleton](https://github.com/CodelyTV/typescript-ddd-skeleton)
33+
34+
This very same basic skeleton philosophy implemented in other programming languages:
35+
36+
- [✨ JavaScript Basic Skeleton](https://github.com/CodelyTV/javascript-basic-skeleton)
37+
- [☕ Java Basic Skeleton](https://github.com/CodelyTV/java-basic-skeleton)
38+
- [📍 Kotlin Basic Skeleton](https://github.com/CodelyTV/kotlin-basic-skeleton)
39+
- [🧬 Scala Basic Skeleton](https://github.com/CodelyTV/scala-basic-skeleton)
40+
- [🦈 C# Basic Skeleton](https://github.com/CodelyTV/csharp-basic-skeleton)
41+
- [🐘 PHP Basic Skeleton](https://github.com/CodelyTV/php-basic-skeleton)
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
module.exports = {
2+
testMatch: ["**/tests/**/*.test.ts"],
3+
transform: {
4+
"\\.ts$": "@swc/jest",
5+
},
6+
};

0 commit comments

Comments
 (0)