Skip to content

Commit

Permalink
feature: fix eslint by creating a package
Browse files Browse the repository at this point in the history
- create eslint-config-custom package
- enable npm workspace feature
- use eslint config in website and root
- duplicate prettier config as well in website
- update npm scripts to match
- remove unused packages
  • Loading branch information
juliencrn committed Sep 19, 2022
1 parent 5c512b6 commit e613ae3
Show file tree
Hide file tree
Showing 19 changed files with 72,329 additions and 75,128 deletions.
31 changes: 4 additions & 27 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,29 +1,6 @@
node_modules
package-lock.json

# Cache
.npm
.cache
.eslintcache

# ignore built packages
node_modules
templates
website
dist
esm
public
generated
*.min.js

# Coverage
coverage

# Output of 'npm pack'
*.tgz

# Mac files
.DS_Store

# Logs
logs
*.log

*.hbs
packages
13 changes: 13 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"extends": ["custom"],
"overrides": [
// Track tree-shaking potential error in the lib
{
"files": ["./src/**/!(*.test|*.spec).ts"],
"plugins": ["tree-shaking"],
"rules": {
"tree-shaking/no-side-effects-in-initialization": 2
}
}
]
}
31 changes: 4 additions & 27 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,29 +1,6 @@
node_modules
package-lock.json

# Cache
.npm
.cache
.eslintcache

# ignore built packages
node_modules
templates
website
dist
esm
public
generated
*.min.js

# Coverage
coverage

# Output of 'npm pack'
*.tgz

# Mac files
.DS_Store

# Logs
logs
*.log

*.hbs
packages
5 changes: 3 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@
"usehooks"
],
"eslint.workingDirectories": [
{ "directory": "lib", "changeProcessCWD": true },
{ "directory": "site", "changeProcessCWD": true }
{ "directory": ".", "changeProcessCWD": true },
{ "directory": "website", "changeProcessCWD": true },
{ "directory": "packages/eslint-config-custom", "changeProcessCWD": true }
]
}
Loading

0 comments on commit e613ae3

Please sign in to comment.