Skip to content

Commit

Permalink
version 3.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
stagas committed Aug 4, 2022
1 parent 9055936 commit d96d981
Show file tree
Hide file tree
Showing 20 changed files with 279 additions and 236 deletions.
4 changes: 4 additions & 0 deletions .eslintrc.js
Expand Up @@ -14,14 +14,18 @@ module.exports = {
ignorePatterns: ['dist', 'node_modules'],
plugins: ['import'],
rules: {
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-empty-interface': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-extra-semi': 'off',
'@typescript-eslint/no-inferrable-types': 'warn',
'@typescript-eslint/no-namespace': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-this-alias': 'off',
'@typescript-eslint/no-unused-vars': ['error', { args: 'all', argsIgnorePattern: '^_' }],
'@typescript-eslint/no-var-requires': 'off',
'no-cond-assign': 'off',
'no-empty': 'off',
},
}
8 changes: 8 additions & 0 deletions .gitattributes
@@ -0,0 +1,8 @@
* -linguist-detectable
bench/** linguist-detectable
src/** linguist-detectable
example/** linguist-detectable
test/** linguist-detectable
types/** linguist-detectable
*.ts linguist-language=TypeScript
*.html -linguist-detectable
3 changes: 1 addition & 2 deletions .gitignore
@@ -1,6 +1,5 @@
coverage
dist
node_modules
.husky
package-lock.json
package-lock.json
.swc
2 changes: 1 addition & 1 deletion .npmrc
@@ -1,2 +1,2 @@
package-lock=false
package-lock=false
access=public
3 changes: 0 additions & 3 deletions .prettierignore

This file was deleted.

9 changes: 0 additions & 9 deletions .prettierrc

This file was deleted.

62 changes: 57 additions & 5 deletions .pull-configs.js
@@ -1,3 +1,4 @@
const fs = require('fs')
const { pullConfigs } = require('pull-configs')

const local = __dirname + '/'
Expand All @@ -6,12 +7,63 @@ const remote = 'https://github.com/stagas/typescript-minimal-template/raw/main/'
const { assign, omit, sort, merge, replace } = pullConfigs(remote, local)

merge('package.json', (prev, next) => {
assign(prev.scripts, omit(next.scripts, ['build:min']))
// deprecated: now using ~/.trusted-npm-deps per system configuration
delete prev.trustedDependencies

prev.types = next.types
prev.scripts = next.scripts
prev.files = next.files
sort(assign(prev.devDependencies, next.devDependencies))

// never used it - OTR screen acts like review so
// it can be accidentally published anyway. also i dont care
delete prev.private

// deprecated
delete prev.devDependencies['@stagas/documentation-fork']
delete prev.devDependencies['@rollup/plugin-commonjs']
delete prev.devDependencies['@stagas/sucrase-jest-plugin']
delete prev.devDependencies['@web/dev-server-esbuild']
delete prev.devDependencies['@web/dev-server-rollup']
delete prev.devDependencies['@web/test-runner']
delete prev.devDependencies['esbuild']
delete prev.devDependencies['esbuild-register']
delete prev.devDependencies['prettier']
delete prev.devDependencies['terser']
delete prev.devDependencies['vite-web-test-runner-plugin']
delete prev.devDependencies['@swc-node/jest']
delete prev.devDependencies['chokidar']
delete prev.devDependencies['jest']
delete prev.devDependencies['jest-browser-globals']
delete prev.devDependencies['ts-jest']
delete prev.devDependencies['ts-node']
delete prev.devDependencies['wtr-plugin-vite']
delete prev.devDependencies['@stagas/jest-node-exports-resolver']
})
replace('.gitattributes')
replace('.gitignore')
replace('.npmrc')
replace('.eslintrc.js')
replace('.prettierrc')
replace('jest.config.js')
replace('.pull-configs.js')
replace('.swcrc')
replace('dprint.json')
replace('tsconfig.json')
replace('web-test-runner.config.js')
merge('.vscode/settings.json')
replace('tsconfig.dist.json')
replace('LICENSE')

const deprecated = [
'.vscode/extensions.json',
'.vscode',
'.prettierrc',
'.prettierignore',
'example/tsconfig.json',
'vite.config.js',
'jest.config.js',
'web-test-runner.config.js',
]
deprecated.forEach(x => {
try {
fs.rmSync(x, { recursive: true })
console.log('removed', x)
} catch {}
})
25 changes: 25 additions & 0 deletions .swcrc
@@ -0,0 +1,25 @@
{
"jsc": {
"target": "es2022",
"parser": {
"syntax": "typescript",
"tsx": true,
"decorators": true,
"dynamicImport": true
},
"transform": {
"legacyDecorator": true,
"decoratorMetadata": true,
"useDefineForClassFields": true,
"react": {
"runtime": "automatic"
},
"hidden": {
"jest": true
}
},
"keepClassNames": true
},
"sourceMaps": true,
"inlineSourcesContent": true
}
12 changes: 0 additions & 12 deletions .vscode/settings.json

This file was deleted.

7 changes: 7 additions & 0 deletions LICENSE
@@ -0,0 +1,7 @@
Copyright 2022 stagas

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights 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 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.

0 comments on commit d96d981

Please sign in to comment.