Skip to content

Commit

Permalink
merge: release 0.9.0 (#661)
Browse files Browse the repository at this point in the history
  • Loading branch information
NoNameProvided authored Feb 13, 2021
2 parents 2455688 + a9658ac commit f8e00f3
Show file tree
Hide file tree
Showing 237 changed files with 26,922 additions and 15,174 deletions.
34 changes: 34 additions & 0 deletions .eslintrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
parser: '@typescript-eslint/parser'
plugins:
- '@typescript-eslint'
parserOptions:
ecmaVersion: 2018
sourceType: module
project:
- ./tsconfig.json
- ./tsconfig.spec.json
extends:
- 'plugin:@typescript-eslint/recommended'
- 'plugin:@typescript-eslint/recommended-requiring-type-checking'
- 'plugin:jest/recommended'
- 'prettier'
- 'prettier/@typescript-eslint'
rules:
'@typescript-eslint/explicit-member-accessibility': off
'@typescript-eslint/no-angle-bracket-type-assertion': off
'@typescript-eslint/no-parameter-properties': off
'@typescript-eslint/explicit-function-return-type': off
'@typescript-eslint/member-delimiter-style': off
'@typescript-eslint/no-inferrable-types': off
'@typescript-eslint/no-explicit-any': off
'@typescript-eslint/member-ordering': 'error'
'@typescript-eslint/no-unused-vars':
- 'error'
- args: 'none'
# TODO: Remove these and fixed issues once we merged all the current PRs.
'@typescript-eslint/ban-types': off
'@typescript-eslint/no-unsafe-return': off
'@typescript-eslint/no-unsafe-assignment': off
'@typescript-eslint/no-unsafe-call': off
'@typescript-eslint/no-unsafe-member-access': off
'@typescript-eslint/explicit-module-boundary-types': off
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: daily
time: "10:00"
timezone: Europe/Budapest
open-pull-requests-limit: 5
versioning-strategy: increase
commit-message:
prefix: build
include: scope
18 changes: 18 additions & 0 deletions .github/semantic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
titleAndCommits: true
allowMergeCommits: false
scopes:
- deps
- deps-dev
types:
- feat
- fix
- docs
- style
- refactor
- perf
- test
- build
- ci
- chore
- revert
- merge
26 changes: 26 additions & 0 deletions .github/workflows/continuous-deployment-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: CD
on:
release:
types: [created]
jobs:
publish:
name: Publish to NPM
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
registry-url: https://registry.npmjs.org
- run: npm ci --ignore-scripts
- run: npm run prettier:check
- run: npm run lint:check
- run: npm run test:ci
- run: npm run build:es2015
- run: npm run build:cjs
- run: npm run build:types
- run: cp LICENSE build/LICENSE
- run: cp README.md build/README.md
- run: jq 'del(.devDependencies) | del(.scripts)' package.json > build/package.json
- run: npm publish ./build
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
41 changes: 41 additions & 0 deletions .github/workflows/continuous-integration-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: CI
on: [push, pull_request]
jobs:
checks:
name: Linters
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
- run: npm ci --ignore-scripts
- run: npm run prettier:check
- run: npm run lint:check
tests:
name: Tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: ['10.x', '12.x', '14.x']
fail-fast: false
steps:
- uses: actions/checkout@v1
- name: Setting up Node.js (v${{ matrix.node-version }}.x)
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci --ignore-scripts
- run: npm run test:ci
- run: npm install codecov -g
if: ${{ matrix.node-version == '14.x' }}
- run: codecov -f ./coverage/clover.xml -t ${{ secrets.CODECOV_TOKEN }} --commit=$GITHUB_SHA --branch=${GITHUB_REF##*/}
if: ${{ matrix.node-version == '14.x' }}
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
- run: npm ci --ignore-scripts
- run: npm run build:es2015
- run: npm run build:cjs
- run: npm run build:types
22 changes: 22 additions & 0 deletions .github/workflows/lock-closed-issues-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: 'Lock inactive threads'
on:
schedule:
- cron: '0 0 * * *'
jobs:
lock:
name: Lock closed issues
runs-on: ubuntu-latest
steps:
- uses: dessant/lock-threads@v2
with:
github-token: ${{ github.token }}
issue-lock-inactive-days: 30
pr-lock-inactive-days: 30
issue-lock-comment: >
This issue has been automatically locked since there
has not been any recent activity after it was closed.
Please open a new issue for related bugs.
pr-lock-comment: >
This pull request has been automatically locked since there
has not been any recent activity after it was closed.
Please open a new issue for related bugs.
24 changes: 0 additions & 24 deletions .github/workflows/nodejs.yml

This file was deleted.

57 changes: 51 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,52 @@
# Log files
logs
*.log
*.tmp
*.tmp.*
log.txt
npm-debug.log*

# Testing output
lib-cov/**
coverage/**

# Environment files
.env

# Dependency directories
node_modules

# MacOS related files
*.DS_Store
.AppleDouble
.LSOverride
._*
UserInterfaceState.xcuserstate

# Windows related files
Thumbs.db
Desktop.ini
$RECYCLE.BIN/

# IDE - Sublime
*.sublime-project
*.sublime-workspace

# IDE - VSCode
.vscode/**
!.vscode/tasks.json
!.vscode/launch.json

# IDE - IntelliJ
.idea

# Compilation output folders
dist/
build/
node_modules/
coverage/
npm-debug.log
.vscode/
.idea/
.nyc_output/
tmp/
out-tsc/
temp

# Files for playing around locally
playground.ts
playground.js
3 changes: 0 additions & 3 deletions .mocharc.json

This file was deleted.

13 changes: 0 additions & 13 deletions .nycrc.json

This file was deleted.

8 changes: 8 additions & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
printWidth: 120
tabWidth: 2
useTabs: false
semi: true
singleQuote: true
trailingComma: es5
bracketSpacing: true
arrowParens: avoid
8 changes: 0 additions & 8 deletions .travis.yml

This file was deleted.

18 changes: 18 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"address": "0.0.0.0",
"type": "node",
"request": "attach",
"name": "Routing Controller",
"restart": true,
"port": 20001,
"remoteRoot": "/home/nodebrick/application",
"localRoot": "${workspaceFolder}",
}
]
}
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,37 @@
# Changelog and release notes

### 0.9.0

#### Features

- Add support for wildcard "all" routes (ref [#536])
- Controller inheritance - Added missing tests, code samples, and updated documentation (ref [#578][#301])
- Added a useResponseClassTransformer global option (ref [#329])
- Through [#329], it should now be possible to use classTransformer only for input (ref [#179])
- Added support for controller inheritance (ref [#147])
- Update all dependencies and changed it to use npm auto-update patches and minor versions (ex.: "class-validator": "^0.12.2", instead of "class-validator": "0.12.2" (ref [#550])
- Updated project tooling (ref [##618])

#### Fixes

- Input-validation bypass vulnerability (ref [#518])
- Fixed issue that would cause multiple route executions per request (ref [#568])
- Fixed export of SessionParam at index (ref [#526])
- Through [#536], it should now prevent conflicts in routes names (ref [#547])
- Through [#568], it should now prevent a single request triggering multiple route executions that would cause Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client issue. (ref [#491])
- Fixed order of global interceptors (ref [#543])
- Fixed incorrect handling of rejected promises from Middleware.use() (ref [#438])
- Through [#329], it should fix performance issue with big json result (ref [#226])
- Through [#329], it should fix problem with mongoose model serialization (ref [#149])
- Local ValidationOptions are not overwriting global defaults (ref [#618])

#### Documentation

- Added TypeDI service decorator to example in README (ref [#643])
- Translate document to Chinese (ref [#574])
- Fix typo in README (ref [#571])
- Add another example for using the response directly (ref [#546])

### 0.8.0 [BREAKING CHANGES]

- [class-transformer](https://github.com/typestack/class-transformer) and [class-validator](https://github.com/typestack/class-validator) are now peer dependencies.
Expand Down
12 changes: 6 additions & 6 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License
The MIT License

Copyright (c) 2018 TypeStack
Copyright (c) 2015-2020 TypeStack

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand All @@ -9,13 +9,13 @@ 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 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.
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
Loading

0 comments on commit f8e00f3

Please sign in to comment.